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
-
Linking to press coverage, reciprocal links?
We have been generating decent online press coverage with links to our site thanks to our PR agency and I have been asked to link to the online coverage from our website in a 'press coverage' section. My question is would google consider links from our site to the online press coverage as reciprocal links? Thanks
Link Building | | gavinr
Gavin0 -
Google Website Ranking Problem
I have a website with not so big amount of backlinks and PA 16 DA 6. I try to search it in semrush and its do not show me any result for it. But I have different website with DA 18 and PA 9 and it is indexed in google. It is have 4 keyword not so well but at least it is indexed and I can begin to bring backlinks and blogs and it will grow up. What can be problem about this website. I do not give website link here to avoid problem. But i can send link in private. But what you can recommend to me to do to make this website show up in google.
Link Building | | flickshine0 -
Link Requests in Order Confirmation Emails- Still a good idea?
I found this post from Rand from 2008 http://moz.com/blog/headsmacking-tip-1-link-requests-in-order-confirmation-emails 5 years later I'm wondering in a "no-follow" for all unnatural links in the google world we currently live in, is it still a good idea? Also does is really work? or does it annoy the customer? would it be better to use that space to up sell to your customer?
Link Building | | PaddyDisplays0 -
The No of Sites linking to www.apollopowersystems.com is 50 as per Alexa, but Moz shows that the no of sites linking is 23\. The no has increased in Alexa but in Moz the no is 23 since 3 months. Why is this Difference?
Hi There, As I am new to SEO, so the problem that I am listing below may seem very naive. Please help me out. Please explain me the difference between the no of backlinks of the website, www.apollopowersystems.com as per the websites below. The nos are completely different as per the websites below: As per www.moz.com the no is 23 As per www.ahrefs.com the no currently is 586 As per www.alexa.com the no is 50 Please tell me why these nos are different. Looking forward to hear from you at the earliest. Thanks in advance.
Link Building | | KDKini0 -
Link building for eCommerce website (Software Products)
Hi. We have two websites, where we develop extensions and templates for various CMS. Thats like , we have around 500+ specific products pages now and we have optimized each and every product page with natural SEO techniques. No over at all. Im very specific about it. But I want to know, how to make a link building plan for those sites. Can anyone help ?
Link Building | | mageclub0 -
Google notice of unnatural links - no penalty
my site just received this warning on 3/18. I haven't seen any rankings drop or anything... i don't know why i got this as i really don't build links in a frowned upon way. Anyone know if you get penalized for this, and if so, how long after you get the message does the penalty kick in, and what is the penalty.... Also, if i gave you guys my domain name do you think you'd be able to tell which links would cause this message? thanks
Link Building | | Prime850 -
Link building
i want to ask a question. i am sure this is kind black hat seo. look at this web site http://www.199999dollars.com/ if we also create website like this and put a banner as domain for sale and in the footer put back links to our domain ? thanks
Link Building | | idreams0 -
Link Churn - where have all my links gone?
I am sure most of you have asked yourself the question I'm asking right now.. Where have all my links gone? I am starting to get twitchy now. I would estimate we have lost around 60% of our links in the past 3 weeks. Does anyone have any comeback stories? Feel like I am back to the start again. I have made a number of changes on the site not least removing a reciprical link page.. that had over 200 links on it but from reading one of Rand's tweets is it true that linking out could be good again?
Link Building | | robertrRSwalters0