Is this link follow or nofollow? Does it pass linkjuice?
-
I have been seeing conflicting opinions about how Google would treat links using 'onclick'.
For the example provided below: Would Google follow this link and pass the appropriate linking metrics(it is internal and points to a deeper level in our visnav)?
=-=-=-=-=-=-=
<div id='<a class="attribute-value">navBoxContainer</a>' class="<a class="attribute-value">textClass</a>">
<div id="<a class="attribute-value">boxTitle</a>" onclick="<a class="attribute-value">location.href='bla</a>h.example.com">
<div class="<a class="attribute-value">boxTitleContent</a>" title="<a class="attribute-value">Text Here</a>"><a href<a class="attribute-value">Text Here</a>"><a ="blah.exam.cpleom">Text Herea>div> ``` =-=-=-=-=-=-= An simple yes/no would be alright, but any detail/explination you could provide would be helpful and very much appreciated. Thank you all for your time and responses.
-
Since the onclick event is a Javascript issue it's to all intents and purposes ignored by the search engines. What counts is whether or not your link appears in the href attribute, and whether or not the link is nofollowed. If you do not have it set to nofollow, there is a slight chance they would follow it, but as stated above, Google is pretty good about parsing javascript links.
-
I didn't know that marking a Good Answer would mark the thread as Answered.
Still looking for responses; hope the 'Answered' tag doesn't cause too many people to pass the topic over.
-
Fair enough! If there are conflicting opinions, I'll be surprised. Google has said since about 2008 or 09 that they are parsing Javascript functionality. Something about creating virtual link structures for spiders, blah blah but that's irrelevant really.
Anyway, good luck!
-
Yes, the code isn't posted here 'as-is'.
I appreciate the quick response and the explination. I will wait for some other voices to chime in with their thoughts but I suspect they will mirror yours (although I am very interested in conflicting opinions if they are out there).
-
Well I'm assuming this code is modified and isn't live anywhere as it's kind of a mess and I don't mean formatting-wise. That said, clearly your question is mainly on the div onClick functionality and whether or not that passes link juice.
To my knowledge, so long as the href is in place you will be fine. Google parses Javascript functionality pretty well and this is one of the simpler JS functions around.
So my answer is: yes.
-
Tabbing seems to have scrunched the code, maybe this is easier to read
<div id='<a rel="nofollow" target="_blank">navBoxContainer</a>' class="<a rel="nofollow" target="_blank">textClass</a>">
<div id="<a rel="nofollow" target="_blank">boxTitle</a>" onclick="<a rel="nofollow" target="_blank">location.href='bla</a>h.example.com">
<div class="<a rel="nofollow" target="_blank">boxTitleContent</a>" title="<a rel="nofollow" target="_blank">Text Here</a>"><a href<a rel="nofollow" target="_blank">Text Here</a>"><a ="blah.exam.cpleom">Text Herea>div>
Hope that helps.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Is a page with links to all posts okay?
Hi folks. Instead of an archive page template in my theme (I have my reasons), I am thinking of simply typing the post title as and when I publish a post, and linking to the post from there. Any SEO issues that you can think of? Thanks in advance!
Intermediate & Advanced SEO | | Nobody16165422281340 -
To nofollow or follow internal links, that is the question...
"...Whether 'tis Nobler in the mind to suffer the slings and arrows of outrageous fortune or..." Okay, I'll drop the Hamlet riff. I'm working on a site with a forum. Top pages may have 20 to 30 answers. Each answer is by a member with an image/link and a name link to their member profile. A member profile may contain alot of info or none. We've noiondexed memeber profile pages, yet we still have these links to member profile pages. Is it better to nofollow these internal links to profile pages or what? Again, with 25 answers on a page and two links per answer to each member profile (image and name), that's a ton of internal links to noindexed pages. Thanks! Best... Darcy
Intermediate & Advanced SEO | | 945010 -
Unnatural links to your site—impacts links
I got message in my Google webmaster tool: Unnatural links to your site—impacts links Does anyone knows the difference between "Unnatural links to your site—impacts links" and "Unnatural links to your site" Thank you Sina
Intermediate & Advanced SEO | | SinaKashani0 -
Wikipedia links - any value?
Hello everyone. We recently posted some of our research to Wikipedia as references in the "External Links" section. Our research is rigorous and has been referenced by a number of universities and libraries (an example: https://www.harborcompliance.com/information/company-suffixes.php). Anyway, I'm wondering if these Wikipedia links have any value beyond of course adding to the Wiki page's information. Thanks!
Intermediate & Advanced SEO | | Harbor_Compliance0 -
Redirect ruined domain to new domain without passing link juice
A new client has a domain which has been hammered by bad links, updates etc and it's basically on its arse because of previous SEO guys. They have various domains for their business (brand.com, brand.co.uk) and want to use a fresh domain and take it from there. Their current domain is brand.com (the ruined one). They're not bothered about the rankings for brand.com but they want to redirect brand.com to brand.co.uk so that previous clients can find them easily. Would a 302 redirect work for this? I don't want to set up a 301 redirect as I don't want any of the crappy links pointing across. Thanks!
Intermediate & Advanced SEO | | jasonwdexter0 -
To recover from Penguin update, shall i remove the links or disavow links?
Hi, One of our websites hit by Penguin update and I now know where the links are coming from. I have chance to remove the links from those incoming links but I am a little confused whether i should just remove the links from incoming links or disavow the links? Thanks
Intermediate & Advanced SEO | | Rubix0 -
Block Level Link Juice
I need a better understanding of how links in different parts of the page pass juice. Much has been written about how footer links pass less juice than other parts of the page. The question I have is that if a page has a hypothetical 1000 points of Link Juice and can pass on +/-800 points via links, and I have 1 and only 1 link in the footer to another page, does it pass the full 800 points? Or... since footers only pass a small fraction of link juice, it passes lets say 80 points, and the other 720 points stays locked up on the page. This question is a hypothetical - I'm just trying to understand relationships. I don't know if I've explained the question too well, but if someone could answer i it, or point me in the right direction, I would appreciate it.
Intermediate & Advanced SEO | | CsmBill0 -
Link Acquisition - link building
When using Site Explorer to find out my competiters links so I can do some link aquisition SEO do I look for the "inbound" links or or "linking domains"? Also, what filters should I choose? I want to make a spreadsheet as Rand suggested in his video and start to prioritize my link building.
Intermediate & Advanced SEO | | musicforkids0