Search Engine Optimisation – Ensuring Valid and Optimised HTML Code

You have built your website, your design team have ensured that it looks good, but has this been properly optimised with regard to the underlying HTML Code? There are only a few tested rules about what HTML tags to use and a good design team will ensure the web site conforms to them. However, care should be taken if your site is built with a system where you may not have direct access to the underlying HTML code which it produces. This includes WYSIWYG editors or even systems like ASP.NET web forms where some of the HTML code can be produced when the page is to be rendered in the browser. Furthermore, systems like ASP.NET use “adaptive rendering” whereby some of the code that is produced depends on the browser that you are using. It is important to know if this is the case in the system that that you are using to develop your web site.

Valid HTML code is both important to how humans as well as search engine robots see your web site. Different browsers do not handle invalid HTML code in the same way. Internet Explorer in the most part will simply cover it up, whereas other browsers will usually be affected more. Typically, you may not see the problem at the time, and the problem will manifest itself in some unexpected way when a change is later made to the page concerned – which can take a while to track down if the symptom appears unrelated to where the problem lies. Other effects may be increased response times – especially in situations of missing enclosing tags as the browser works hard to deal with copious volumes of code which would have been much reduced had the closing tag been in the correct place.

The best resource to test your HTML validity is the W3 validator at http://validator.w3.org. If your web site uses adaptive rendering, your best bet is to validate by URI – this will be closest to how the search engines will see the page. Validating by file upload is only applicable to files containing pure HTML, and validating by direct input will not give a true picture if it is based on source code which has been adaptively rendered for the browser from which the source was obtained. If you are unsure of this, check with your developers. Also make sure they haven’t put anything in the code to customise the adaptive rendering for Google and the other search engines – all this is possible in a system like ASP.NET.

So you have constructed your home page and the validator finds something wrong with it that you cannot see by looking at the code. How do you deal with this? Chances are that this is something like an ASP.NET component for which the HTML is rendered by the ASP.NET engine at the time the page is displayed. It may be possible to avoid validation errors simply by adjustment of the component, or even using an alternative approach such as using the generic HTML controls rather than the ASP.NET web controls. However, ASP.NET does allow the use of “HTML Adaptors”. This gives you control over the HTML code which a specific component will produce, and this can be made browser dependent if desired. This may already be requested by the Design department, so that they can target the correct HTML tags with their CSS. However, this can also apply to the page Title and Description tags. These are not of interest to the CSS Designers, but in ASP.NET, a page Title which is configured to be modified can be rendered in a very untidy form and this may or may not affect the way the search engines view your site and may give a confusing view to the various tools that are available for SEO work.

In conclusion, understand how the HTML code is produced by your developers, especially if there is a chance that some or all of it is rendered at run time when the page is displayed, especially if this is adaptively rendered. Ensure that the code produced is clean and valid. Use the W3 validator to check validity, and the various SEO tools to check if it is clean – if they have a problem reading your page, then so will the search engine robots. This is equally as important as the text of your web page allowing the search engines to index your web site properly.

 

 

[tags]

 

Leave a reply "Search Engine Optimisation – Ensuring Valid and Optimised HTML Code"

Your email address will not be published. Required fields are marked *

Rating*