Forum Moderators: open
I have been searching the forum hi and low, found several links to several threads (many of them gave me 404s, though), but many were outdated, and none gave any final proof or strong argumentation of whether javascript links are found by Googlebot and followed or not?
Can someone produce something worthwhile?
Cheers,
Dan
I had the problem of duplicate content due to a "print this page" link on every normal page, which had different urls. To stop this, I changed all "print" links to javascript only links, moved them to a /print/ folder and banned that folder in robots.txt.
The result? All the NEW URls got indexed! I figured I had double protection from the links being hidden within JS AND the ban of the /print/ folder in robots.txt. Nope!
Google will find JS links.
Google will index(not crawl) those links, even if they are protected by robots.txt.
Thanks for responses.
Birdman: To clarify: By "not crawl", do you mean that they will not follow the link, then? Just register (index) that it's there?
Also, have you seen any article or other page confirming this?
Cheers,
Dan
In javascript, urls are recognised if they are fully qualified, ie they begin 'http://...'
So far as I am aware, javascript links do not pass PR but that may depend on how they are formed.
Kaled.
This was a year ago, maybe things changed. Also, maybe my JS was really badly written.
But I recomd you do not exclusivelly use JS for links. Plug in a pure A tag link somewhere (like the link listings at the bottom of a page for example) just to be safe
Birdman: To clarify: By "not crawl", do you mean that they will not follow the link, then? Just register (index) that it's there?
In my case above, they only indexed the link, without actually crawling the page because of the ban in robots.txt. There is no title or description in the SERPs, only the URI.
I think it depends on how you write your JavaScripted links
Birdman