Posts that Nyks is monitoring

Subscribe to Posts that Nyks is monitoring 10 posts found

Nov 28, 2007
sizzlemctwizzle 120 posts

Topic: Correct Google URL Redirects

i just highlight the area of the link and Right-click "View Selection Source". another useful tip is to use this bookmarket to view rendered source:

if (document.createElement){void(pstTagName='%s');void(head=document.getElementsByTagName('head').item(0));void(script=document.createElement('script'));void(script.src='http://javascript.gibney.org/editor_v2.js');void(script.type='text/javascript');void(head.appendChild(script));}

 
Nov 27, 2007
Descriptor 757 posts

Topic: Correct Google URL Redirects

Yes, that's probably the best approach. It's direct and gets rid of the function you don't want.

An easy way to view the source of links...
Click somewhere before the link
Press TAB until the link you want is outlined
Hold SHIFT and press the right-arrow to select the link (or the down-arrow)
Right-click the selection (or use the Menu meta-key, right next to the Windows key)
Select "View Selection Source" from the menu.

This will show you the WYSIWYG rendered source around the link.

 
Nov 27, 2007
sizzlemctwizzle 120 posts

Topic: Correct Google URL Redirects

unsafeWindow.rwt = function(){ return true; }
This got rid of the rewriting for me.

 
Nov 26, 2007
Descriptor 757 posts

Topic: Correct Google URL Redirects

I don't use iGoogle but I think there's an option to "not remember search results" or something like that, it was mentioned in one of those discussions.
Since you use iGoogle there are two issues - click monitoring and link rewriting.

I don't really want to create an account to see what they do to links, so I don't know for sure. But either you can disable it in your preferences, or on the search results page, or try CustomizeGoogle, or try the script Mikado posted which will rewrite links (but a bit "wordy" I think). Or you may actually want this in order to use the iGoogle features. I can't suggest anything since I can't see what they do.

If you don't want them to monitor your clicks, as they do to all Firefox users (and maybe other browsers), then you want to somehow disable that function. window.clk is the function I saw and the first line of code I posted causes that function to do nothing, at least until they change it. This doesn't remove the "onmousedown" event, which may be used for something else. You can remove the "onmousedown" attribute, but they could later define some other event or the same event another way.

There's no doubt a better way to write a script, but it depends on what you want to do - always prevent the redirects or prevent the click tracking, or both.

 
Nov 26, 2007
Descriptor 757 posts

Topic: Correct Google URL Redirects

There are lots of ways to disable this in Greasemonkey...

Redefine the function

unsafeWindow.clk = function(){ return true; }

or Remove mousedown events...

for(var i=0; i < document.links.length; i++){
  document.links[i].removeAttribute('onmousedown');
}

or use the SpiderMonkey built-in method (according to wiki)

Array.forEach(document.links, function(link){ link.removeAttribute('onmousedown') });

 
Nov 26, 2007
Descriptor 757 posts

Topic: Correct Google URL Redirects

No, I checked a few days ago and they did this if the User-Agent header contained the word "Firefox", which my browser isn't, there is a onclick handler and "clk" function.
I might complain about this if I knew who to complain to. Also I noticed Google's HTML is a bit less than "acceptable", which removes another little bit of respect I had for them (but perhaps still better than any other search engine).

Seems they've been doing this since August 2005, and I've never seen it. I found some info on this...
Google stealthily monitoring clickthroughs from search-results
Is Google click-tracking regular search results?

However the "clk" function that I looked at does not create a redirect link, but it creates a new Image who's source is generated from the link you click. This "fake image" request appears right after you click the link and looks something like...

http ://www.google.com/url?sa=T&ct=res&cd=4&url=http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FGreasemonkey&ei=pTRACKINGCODEA

An extension that claims to disable it - CustomizeGoogle Firefox extension
also Controle de Scripts can completely disable onmousedown events.

 
Nov 23, 2007
Mikado 566 posts

Topic: Correct Google URL Redirects

Really? That's interesting. Check result links, don't they have onmousedown attribute which calls some url rewriting function? Maybe you already using some script that gets rid of this?

 
Nov 23, 2007
Descriptor 757 posts

Topic: Correct Google URL Redirects

Google isn't doing this to me, and I don't see anything that would cause this. The ads do something like this but not the search results. The first couple results are often ads, they have a different background color.

Maybe the Google Toolbar or something else is causing this.

 
Nov 23, 2007
Mikado 566 posts

Topic: Correct Google URL Redirects

for (var xpr = document.links, i = xpr.length - 1, hr; i >= 0; i--) {
	xpr[i].removeAttribute('onmousedown');
	if ((hr = xpr[i].href).substr(0, 28) == 'http://www.google.com/url?q=') xpr[i].href = unescape(hr.substring(28, hr.indexOf('&', 28)));
}

Also, I believe there are already 10 to 50 similar scripts, but writing this one is easier than searching :)

 
Mar 25, 2007
Henrik N 217 posts

Topic: List installed Userscripts?

They're listed in config.xml inside the scripts directory.