Post Reply 
Strange results from Exceptions-U changes
Dec. 23, 2011, 02:39 AM (This post was last modified: Dec. 23, 2011 04:53 AM by JJoe.)
Post: #15
RE: Strange results from Exceptions-U changes
(Dec. 22, 2011 11:42 PM)zoltan Wrote:  Is the $SET necessary before each $JUMP because the $SET(0=f_ua_ie.) can't function independently of the others?

No. The Proxomitron executes the instruction when it sees it.
Actually, $SET() in front of a $JUMP() just slows things down.
$JUMP() makes the browser request a new page. All begins again.
$RDIR() hides the change. All continues on.
However, putting $JUMP() everywhere allows me to quickly switch to $RDIR(). It's probably a bad habit.

In this case, you could

Code:
www.google.com/ $SET(0=f_ua_ie.)(webhp\?hl=en$JUMP(http://www.google.com/advanced_search)
                |firefox$JUMP(http://www.google.com/advanced_search)
                |imghp$JUMP(http://www.google.com/advanced_image_search?hl=en)
                |?
                |$JUMP(http://www.google.com/advanced_search))

or even quicker since the false header is actually lost with $JUMP().

Code:
www.google.com/ (webhp\?hl=en$JUMP(http://www.google.com/advanced_search)
                |firefox$JUMP(http://www.google.com/advanced_search)
                |imghp$JUMP(http://www.google.com/advanced_image_search?hl=en)
                |?$SET(0=f_ua_ie.)
                |$JUMP(http://www.google.com/advanced_search))



(Dec. 22, 2011 11:42 PM)zoltan Wrote:  And I don't understand this part.

Code:
if ? then $SET(0=f_ua_ie.)
else $SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_search)

Having already matched the www.google.com/? pages to $JUMP away from,
if www.google.com/ is followed by anything $SET(0=f_ua_ie.)
else www.google.com is not followed by anything so $SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_search)

I could have put (^?) in the "else" but the rest of the expression makes it unnecessary.
I could have used (^?) in the implied "if" but most of the time the filter is matching www.google.com/somethinghere.

(Dec. 22, 2011 11:42 PM)zoltan Wrote:  I had been using "www.google.com/(^?)" because I thought it limited the scope so that only "www.google.com" would match -- meaning "www.google.com/images/" would not. The "(^?)" was to prevent it from redirecting other google pages like image search, news, or maps.

It does. You aren't wrong.

(Dec. 22, 2011 11:42 PM)zoltan Wrote:  Code:
http://www.google.com/ ((^?)$SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_search)
|webhp\?hl=en$SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_search)
|firefox$SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_search)
|imghp$SET(0=f_ua_ie.)$JUMP(http://www.google.com/advanced_image_search?hl=en))

It redirects google to advanced, but it shows the wrong results page.

You are setting the header for
www.google.com/(^?)
www.google.com/webhp\?hl=en*
www.google.com/firefox*
www.google.com/imghp*

You need to add a line that sets the header for the advanced search pages and associated www.google.com/* not covered by your expression.


Code:
www.google.com/ ((^?)$JUMP(http://www.google.com/advanced_search)
                |webhp\?hl=en$JUMP(http://www.google.com/advanced_search)
                |firefox$JUMP(http://www.google.com/advanced_search)
                |imghp$JUMP(http://www.google.com/advanced_image_search?hl=en)
                |$SET(0=f_ua_ie.))

BTW, you could also remove the space after www.google.com/

HTH

Edit: Grammer
Add Thank You Quote this message in a reply
[-] The following 1 user says Thank You to JJoe for this post:
zoltan
Post Reply 


Messages In This Thread
RE: Strange results from Exceptions-U changes - JJoe - Dec. 23, 2011 02:39 AM

Forum Jump: