[Case Study] Does Googlebot follow javascript generated links?

Han_Solo

Newbie
Joined
Sep 26, 2012
Messages
42
Reaction score
20
I found a forum that allow put HTML tags in signature. It's possible to include javascript code. I made a simple script that replace one navigation link in forum header with my URL:

var links = document.getElementsByTagName('a'); links[0].href = 'http://mydomain.tld/mypage';

Users (with enabled js in web browser) will see link to my site, but does Googlebot follow it? I made that link to subpage created 2 years ago, but not indexed yet (it has any backlinks and isn't linked from other pages on this domain). In next days I'll check that the page was indexed or not and post update. :)
 
Last edited:
I found a forum that allow put HTML tags in signature. It's possible to include javascript code. I made a simple script that replace one navigation link in forum header with my URL:
Code:
[FONT=monospace][/FONT]
Users (with enabled js in web browser) will see link to my site, but does Googlebot follow it? I made that link to subpage created 2 years ago, but not indexed yet (it has any backlinks and isn't linked from other pages on this domain). In next days I'll check that the page was indexed or not and post update. :)

Should just put an AdSense banner there ;). Also, cloaking your link from users but making it visible to Google is a good idea as well.
 
Googlebot more or less adds links to its "link inventory" for a page when parsing js, but generally doesn't apply DOM manipulations when indexing the page, but does thumbnail after all the dynamic stuff that they'll do has done its business. It's tried to snoop links from js since before it could parse js, so something like document.write('<a href="/blerg">blerg</a>') has been spiderable for a long time. From what I observe on lyrics sites they mostly disregard any dynamic content that involves an origin change.
 
Googlebot more or less adds links to its "link inventory" for a page when parsing js, but generally doesn't apply DOM manipulations when indexing the page, but does thumbnail after all the dynamic stuff that they'll do has done its business. It's tried to snoop links from js since before it could parse js, so something like document.write('<a href="/blerg">blerg</a>') has been spiderable for a long time. From what I observe on lyrics sites they mostly disregard any dynamic content that involves an origin change.

That is the absolute best answer that anyone could possibly post on here. Upping your rep.
 
Perfect Answer men...

Googlebot more or less adds links to its "link inventory" for a page when parsing js, but generally doesn't apply DOM manipulations when indexing the page, but does thumbnail after all the dynamic stuff that they'll do has done its business. It's tried to snoop links from js since before it could parse js, so something like document.write('<a href="/blerg">blerg</a>') has been spiderable for a long time. From what I observe on lyrics sites they mostly disregard any dynamic content that involves an origin change.
 
I found a forum that allow put HTML tags in signature. It's possible to include javascript code. I made a simple script that replace one navigation link in forum header with my URL:



Users (with enabled js in web browser) will see link to my site, but does Googlebot follow it? I made that link to subpage created 2 years ago, but not indexed yet (it has any backlinks and isn't linked from other pages on this domain). In next days I'll check that the page was indexed or not and post update. :)

Update: After 4 days page is indexed.
 
Back
Top