PDA

View Full Version : "links embedded in javascript" ?


rbateman
16-06-2003, 17:58/05:58PM
Can anyone tell me if the following code constitutes "links embedded in javascript" please.

<a href="index.html"><img src="images/logo.gif" width="122" height="89" alt="etraffic solutions home" border="0"></a><img src="images/header2.gif" width="60" height="89"><a href="index.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('nav_home','','images/nav_home_over.gif',1)"><img src="images/nav_home.gif" width="58" height="20" name="nav_home" alt="home" border="0"></a>

The article that mentions this peril is located at
http://tinyurl.com/eh3f
in paragraph #7

Thanks!

Rick Bateman
Search Engine Optimist : )

chrishirst
16-06-2003, 19:12/07:12PM
The code you have posted is a M$ FP generated link menu using <a> tags and some javascript for mouseover image swapping, The links are not embedded in the javascript.
The embedded links refers to the method in javascript of putting the link into an array then calling a function with the array index as a parameter or functions like this;


function SiteDesign()
{
document.write('This site designed and maintained by ');
document.write('<a href="http://www.somesite.co.uk">');
document.write(Somebody</a><br>');
document.write('Contact:- <a href="mailto:webmaster@somesite.co.uk?subject=This Website">Webmaster</a>');
}


function EmailName(user,PromptText)
// write email address on page to hide from 'spiders'
// recipient name passed as user. Friendly name passed as PromptText
// change domain name in this script before using on a site
{
domain = "somesite.co.uk";

document.write('<a href=\"mailto:');
document.write(user);
document.write('@');
document.write(domain);
document.write('\">');
document.write(PromptText);
document.write('</a>');

}


The scripts above write the text onto the document but will only be run by a javascript enabled browser and will not be triggered by the spider\crawler, therefore there will be no links for the crawler to follow. I use the above functions to hide email addresses from harvesters and to display site links that I don't want to be spidered

BTW feel free to use the scripts if you want to cut down on spam from random harvesters (it's far easier to set up than webpoison)

Chris.

rbateman
16-06-2003, 19:55/07:55PM
Awesome! Thanks Chris!

Rick