Stop Google Auto Link Feature


Link to Example


Link to Dreamweaver Behaviour Extension


The script below is designed to disable the Google autolink feature in Internet Explorer. The original version of the script came from Chris Ridings at http://www.searchguild.com/ and that is where all credit should go. However, It seemed to me that the same thing could be done with less script and also not have to use two setTimeout calls. So here is what I came up with.


Configuration


To configure this script follow these steps:


Step 1: Copy the following into the head section of the document


<script type="text/javascript">


// originally from 2005 Chris Ridings http://www.searchguild.com/

// modified by Eddie Traversa 2005 to be leaner and use only one timer

// http://www.dhtmlnirvana.com/ free to use but keep this notice intact.


function handleLinks() {

for (i=0; i < document.links.length; i++) {

if (document.links[i].id.substring(0,5)=="_goog") {

gl= document.links[i].parentTextEdit.createTextRange();

gl.moveToElementText(document.links[i]);

gl.execCommand("Unlink",false);

gl.execCommand("Unselect",false);

}

}

setTimeout("handleLinks()",500);

}

</script>


Step 2: On the body tag of the html document change it so that the body tag looks like the following;


<body onload="handleLinks()">


That's all there is too it. Below the Google Ads is an example containing all the neccassary files in zip format and a Dreamweaver Extension.


Download Stop Google Auto Link Example


Link to Dreamweaver Behaviour Extension


Return To DHTML Nirvana

http://dhtmlnirvana.com/

http://dhtmlnirvana.com/svg/index.htm

http://dhtmlnirvana.com/ajax/ajax_tutorial/

http://dhtmlnirvana.com/alchemy/externalload.htm

http://dhtmlnirvana.com/program/permalink/ajax_history.html

http://dhtmlnirvana.com/content/dhtml.html

http://dhtmlnirvana.com/ajax/gallery/ajaxgallery.html

http://dhtmlnirvana.com/spiritual/2005/05/07/uber-dream-analysis/

http://dhtmlnirvana.com/content/widgets/killautolink/index.html

http://dhtmlnirvana.com/oldalchemy/externalload.htm

http://dhtmlnirvana.com/permalink/wpfe.html

http://dhtmlnirvana.com/svg/intro1.htm

http://dhtmlnirvana.com/program/permalink/ajax_tutorial1.html

http://dhtmlnirvana.com/content/blog.html

http://dhtmlnirvana.com/svg/

http://dhtmlnirvana.com/program/

http://dhtmlnirvana.com/spiritual/

http://dhtmlnirvana.com/alchemy/preload.htm