In order for Google to recognize a hyper-link on your website, does it have to be written in a specific java script?
-
Does it have to read as the following script?
-
Not a problem I find that all too often, if the question is a bit ambiguous - people will ignore it. If there are only a handful of interpretations, I will still try to answer
-
Thank you, that was extremely insightful and helpful.
-
Just so you are aware, the code-sample which you supplied is HTML and not JavaScript (or for that matter, any type of script. Scripting languages include JavaScript, Python, Ruby, Perl etc).
You may be asking one of two things (I think!):
1) Is there a set HTML format for hyperlinks which Google knows how to read?
Yes, and you can find **information all about ** conventional use of the <a></a><a>(HTML) tag here:</a>
<a></a>
<a></a>
HTML is a static language and is not (unlike many scripting languages) 'object oriented'. You don't define "<a>" and as such</a> <a>is not interpreted based upon your programmed parameters.</a> <a>always means the same thing (to a a web browser). Sure stuff like CSS can style links in different ways, JavaScript can modify</a> <a>tags by injecting event-tracking attributes etc (also a common use of jQuery) but fundamentally the usage of</a> <a>is</a> <a>(mostly) universally agreed. So yes - links are coded according to conventions and Google will interpret those widely accepted conventional use-cases, as well as a few more experimental deployments (possibly through error handling in Google's algorithms). In general, you should follow W3C / W3 Schools guidelines. There are many forms of link (no-followed links, text links, image links) and all are valid but yes - they are predetermined</a>
<a>2) This is the HTML which my JavaScript will output - is it ok?
Yeah it's fine dude. If you can handle JS, you can handle HTML (it's way simpler). One thing though, although Google can deploy rendered (JS-enabled) crawling, that involves using headless browsers and such to render the 'modified' source code (so, what you see in 'inspect element' is the modified source. What you see in "view page source" is different, that's the pre-modified or base-source code).
Usually speaking this takes 10x longer than simple DOM / base-source scrapes. As such if Google were to deploy that tech on every crawl for every page on the web, the efficiency hit to their 'index the web' mission would be colossal. Many studies show that Google will not render JS on all sites (especially one perceived to be low value). Even on sites where they will use this tech, they won't deploy it all of the time. There really is no substitute for forcing your links and content to be readable in the base-source code (un-modified). It's way better for crawlers, way more efficient for them to work with. Just because Google ' can' do something, it doesn't mean they always will. It doesn't mean it's a good idea to ignore basic SEO principles!
Hope that helps</a>
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
-
If I disavow bad links on "disavow link webmaster" will they still show up on my moz reports?
We recently found out we have a lot of bad links linking back to our website from spam sites, I disavowed them through the google disavow link webmaster. On my moz report it still shows the links, is that normal?
Link Building | | Ryan.Cruz0 -
We are moving to HTTPS and wanted to know if our link building efforts were in vain or will the link juice pass to HTTPS?
We are switching to HTTPS and want to make sure the links we've gotten in the past will still transfer since they are pointing to HTTP? I'd hate to go back through and ask people to please add an s to the link.
Link Building | | bryant25560 -
Grr SEO linking.. I am not understanding why I wouldn't have lots more links.. Please help. Thanks
I have done the whole moz open exploer and I am not understanding why my site wouldn’t have more links registering to my website.. I have lots of sites(directorys and 3rd party) with my website domain in them. The only one that is linking to my site is BBB.com and my advertsing with saint paul press. www.somerersetautodealer.com But if I have links with all kinds of automotive directories why wouldn’t they register? I am sure this a simply answer or that I am not understanding something. Thanks for your help! Scott
Link Building | | Scott12340 -
HELP - Should I Disavow SEO, Site Analysis, and Website Worth Links?
I have a gadget site and have MANY links to my site from sites that offer web analysis or SEO tools. For example, the site chkme.com has over 1,000 links to my home page. I don't know who they are, why they are linking to my site, and their site is irrelevant to my industry. Should I disavow links from sites like these? My site seems to be linked to from a lot of "website worth" type sites as well. I think I may have been hit with an unnatural site penalty but I do NO blackhat or any type of link building whatsoever. Thanks in advance 😉
Link Building | | Humanovation0 -
External links - link to third party sites
Greetings! Actually, got an doubt on linking to external site. The thing, i have working for roof marketers site. They have covered roof products. Each of the products have a page along with major keyword. Actually, i do link from other pages[internally]. Meaning,if i see any main keywords in different page then will link that to corresponding page/product[internally].This is what i am doing to get page rank. Now, my doubt. Some of the pages are having link with main keywords which directs to the third party site those who are really producing the products. But, i remove the third party-link which has with main keywords. Since already the site/my client site having pages for that main keywords. But client really want that link. meaning the links which they have given to direct to third party[product producer] site. So what should i do at this case. Can i just past RAW link like [http://www.thirdpartysite.com] or what do i do. But my client wants that link to be in content area. Hope you would understand my long explanation and case Please help us. Thank you
Link Building | | Webworld_Norway0 -
Links from Real Estate Websites Link Page, Do or Don't?
It seems that real estate sites have at times been under heavier scrutiny from the search engines. But real estate agents get networking, which makes acquiring those links a little bit easier. Plus with localization of search, I think real estate sites may give off a good GEO scent. Should SEO's go for links from real estate websites? Does a reciprocal link devalue said links?
Link Building | | Thos0030 -
A good link builder / link building agency for Spanish content
Hi, I am looking for a good link building agency or freelance to execute a link building strategy for the next months. The content is in Spanish. Could anyone recommend me a good agency or a good link builder for Spanish content? Thank you very much! Jorge
Link Building | | jorgediaz0