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
-
Buy domain, redirect, get all the good links (+link juice) and disavow the spammy ones?
There is a domain for sale that has a quite nice profile and a lot of good backlinks, but also quite a few spammy ones. This domain has a Spam Score of 14% acc. to Moz Link explorer, ours has only 2%. My questions: 1. The domain and the good backlinks are related to or close to our content/keywords. But we are worried whether the "spammy" ones will hurt us. Does anyone has experience with this? 2. Would it help if we disavow the spammy backlinks afterwards? And if so, how do we do that? Add new domain to search console, disavow the bad links and then redirect the entire domain to our domain or redirect the domain first and then disavow from our property? Many thanks for your help!
Link Building | | pissuptours0 -
How to get 'Links to you site' via the google search console API?
hey! Any idea how I can download backlinks via the sear console API? This page from Google has a few commands but not the back links one - https://developers.google.com/apis-explorer/#p/webmasters/v3/ Has anyone collected backlinks data in the past? Apprrciate your help! Thanks Arjun
Link Building | | BaselineTry0 -
Why Links from Top Level Domains doesn't Pass Link Equity?
Hello, I have a doubt about Equity-Passing links report of OpensiteExplorer.org According to Sam Weber http://moz.com/community/users/432678 links which pass value from one page to another including followed 301 and Meta refresh links are under Equity-Passing links. I am surprising after looking at the links report generated by opensiteexplorer.org. Most of the article and directory links which have low DA and PA are under Equity-Passing links. Whereas websites like EzineArticle or Articlebase which have good DA and PA are not found in either Equity-passing links or under only nofollow category. Please suggest me if the report of Opensiteexplorer is not good enough or the links from the site like Ezine Article doesn’t pass the link equity. Thanks.
Link Building | | TopLeagueTechnologies0 -
Link building during link removal
We were advised by out outsourced link removal vendor not to build any links while they are removing links pointing to our site. I am worried that our site will lose significant traffic if we dont build any new links while waiting for them to remove links that caused our site to be penalized. What are your thoughts?
Link Building | | WizardOfMoz0 -
Pursuing Links on Sites You Have a Link From
Is it a bad idea to spend resources to get a second link from a site that already links to you? It seems like the marginal value of each additional link is much smaller than the first link.
Link Building | | ProjectLabs0 -
Google sending warnings about Artificial or Unnatural links in Google Webmaster Central
Has anyone seen warnings about Artificial or Unnatural links notice show up in their Google Webmaster central yet? I just looked at each of our clients and had not but after reading the Search Engine Land article at http://searchengineland.com/google-warning-more-about-bad-link-networks-117079 I was wondering what your thoughts were regarding this topic? We are not purchasing links for our clients sites but definitely going out their and building links. Article concerned me that I may run into issues for my link building clients. Thoughts?
Link Building | | jfeitlinger0 -
Search volume on google.no vs google.com for keyword
Anyone know if there is a way to find out search volume for a keyword on google.com vd for instance in our case google.no ? The reason i am asking is that i am ranking 17 on google.com vs 1 on google.no . how do i go about to increase .com ranking ?
Link Building | | danlae0 -
Do affiliate links count for Google?
Hi, I have been reading about affiliate links - links with a tracking code in the URL (i.e.: www.xxx.com/?aff=123456) and I can't find a definitive answer. Does Google count them as natural links or maybe they do not even pass any link juice? And if they don't, what if I get a natural link from a website (without tracking code) and later that website becomes my affiliate? Would the first link still count? I guess that there can't be any certainty about all this, but I would love to know your expert opinions 🙂 Thanks!
Link Building | | jorgediaz0