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
-
Unnatural link Manual Penalty by Google
Hi, Our product Quiz Maker help users to create quizzes and can share, embed etc. We have a link in our embed code which was DoFollow and we've got many doFollow links from the websites on which our quizzes got shared but these links are too old like 2009, 2012 etc. After that, to complying with Google policies, we've changed the dofollow link to nofollow in embed code. Here are two scenarios: 1.) We've too many dofollow links which are too old and we don't have control over it as these are the natural links, given by our users before we changed the embed code link. 2.) Now, we are getting nofollow links from the widget as the embed code consists of nofollow link. Our embed code is editable and user can change it to dofollow or nofollow as per their requirement. Moreover, some people shared quizzes on their website (without using embed code) with dofollow link. But, now, google is taking manual action penalty against us. How we can resolve it as it seriously affects the overall performance of our website. Thanks
Link Building | | SameerBhatia2 -
Large natural products website owns education website. Should relationship be disclosed?
Hello All - I'm working on a content strategy for a large natural products company. In general it's difficult for articles about the natural products industry written written on commercial company sites to show up in the SERP. Most of the results come from large educational sites and blogs with no obvious affiliation (or products for sale). This company also owns an educational site - one that would be much easier to get content on the first page of the SERP for. The 2 sites are hosted on the same server. My question is - does this website relationship look fishy? Is it a grey area to create content for the educational site - content where the purpose is #1 education, but #2 - to promote products from the main site and send traffic to the main site. I do think it's important to note that the main company site does not actual sell any products there (products are sold on Amazon and on shelves in stores). I appreciate your thoughts!
Link Building | | JBMediaGroup0 -
Does google will see this has a 301 permanent redirect and will penalized my website?
Hi, I got a website that have a lot of information on job posting. The domain name will be new but i just want to redirect all of the old single job pages (around 300 pages). To the new domain pages but keep the old domain because it's already been indexed by google. The design will change but the content will kinda be the same. Is this a good approach? Does google will see this has a 301 permanent redirect and will penalized my website? Thanks alot
Link Building | | bigrat950 -
Links Removed from Site but not Google Webmaster Tools
I have a new client who has been fighting to get past an unnatural links penalty. One of the biggest reasons behind it was that they paid to get a followed link/ad on a blog network, well this ad ended up being a site wide link which ended up giving them thousands of back links within a few days. After getting the owner of the blog network to remove the link i manually spot checked a handful of pages and used screaming frog to crawl looking for a link referencing their site. From what i can tell they are all gone. However they are still in Google Webmaster Tools as well as Google's index and it has been a couple months since they have been removed. Does anyone have any advice on getting them removed from Google's entities even though they are already off of the website? Thank you in advance,
Link Building | | kchandler
Kyle0 -
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 -
Links in google+ profile
THe links people can add in the about part of a google+ profile - do they have any effect on rankings? is this worth doing for link building?
Link Building | | pauledwards0 -
Which link should I use for link building?
I have an article which have high rank on Google. But recent, I use mod rewrite url so this article have new url. old: mywebsite.com/c1/p-1 new: mywebsite.com/c-e/p-1 Now, google is indexing old url. I want to ask when I build linking to my site, which link should I use for link building? I should build linking for new url or old url. Thanks
Link Building | | sonzin13040 -
Link building for rankings VS Link building for relationships
A Big Shout To Everyone -- Good Morning and What's Up 🙂 As I read today through seomoz professional guide to link building and the section why link building matters and in addition to this a newsletter I received today that changed my whole thinking towards link building for rankings vs for relationships. It is already happening on social networks if you are active there, but what about on your website. What are your thoughts on the following ? Google's job is provide the most relevant results to surfers online, and looking the link profile of a site & the page itself is the key to determining which page to serve on plate to the surfers link query ! Webmasters Site Objective:
Link Building | | helpwanted
I think that we as webmasters have to ask ourselves what do we want to achieve with link building. To get quick traffic or build slow authority links, high rankings, lead generation, sales & other things here I may be missing etcccc Other Objective Networking & Relationship Building Alliances : What I discovered today is that building links for 1st page rankings are great and will provide me with steady traffic, but not all of it is targeted traffic, but what else can I do to bring targeted traffic and at the same time try to build alliances with other related non competing business owners online. The idea... is to apply old school networking / relationship building alliances to get targeted traffic to my site that can actually benefit from my services. How Do We Achieve This I become a editor for approving resource links for me site, only the best will be placed on my site as a resource. Build a valuable tightly themed categorized resource section with related non competing resources that can help my sites visitors find what they are looking for, send visitors to non competing resources that may purchase their services which helps me build a relationship with them, and may can with rankings as well, provided I am selective with my qualification process. Questions & Concerns Below : What should I be thinking about when creating a resource categorized links page How many outgoing do follow links should I allow from this links partner page How will this links resource page affect my own SE 1st Page Rankings and is it worth it based on getting targeted traffic Any pros / cons I may be missing here0