[QUESTION] Javascript Text Links??

deth_by_uv

Power Member
Joined
Feb 26, 2008
Messages
525
Reaction score
428
I'm working on a client's site that runs on a corporate site builder type of deal and a lot of the sites functions runs Javascript...which I am no expert at...

I was trying to add anchor text links for some on-page SEO and realized that the built in editor wasn't capable of making links to other pages, how stupid is that?...I thought that was a pretty critical thing...

So I found some code on the net which takes care of the job fine enough:

<a name="" onClick="window.open('http://javascript.internet.com/new')">Click Here</a>

The code above for text link works, opens page in a new tab and all, but it doesn't turn the text blue like in HTML and I was just wondering if search engines cared whether or not the text links were in HTML or Javascript?...

Appreciate any help...
 
To my knowledge search engines don't get along with anything javascript, so they won't be crawling through the pages that those links link to.

The editor let you put in
Code:
<a name="" onClick="window.open('http://javascript.internet.com/new')">Click Here</a>
but not
Code:
<a name="" href="http://javascript.internet.com/new">Click Here</a>
? Thats a bit odd as they are basically the same code but the latter one is easier for search engines to crawl through.
 
Yeah, that stupid editor is really chafing my balls...when I tried using the second, friendlier code, the editor won't save but with the javascript code it saves just fine...oh well :) ...
 
A while ago I did something like this:

onClick="javascript:redirect('http://site.com/page')"

I secifically didn't want google to spider the page but in fact they did !

Of course it's not the way to do it if you want to encourage spider visits, but it doesn't stop them.
 
Back
Top