Take the 2-minute tour ×
Salesforce Stack Exchange is a question and answer site for Salesforce administrators, implementation experts, developers and anybody in-between. It's 100% free, no registration required.

By default, SFDC pages (including Visualforce) are served with the DOCTYPE for HTML 4.01 Transitional (!!!) -- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

According the the VF documentation, we can serve VF pages as any doctype we want, including HTML5:

The HTML document type definition (DTD), or doctype, that describes the structure of the rendered page. If not specified, this value defaults to "html-4.01-transitional", which results in a doctype of . Possible values for this attribute include "html-4.01-strict", "xhtml-1.0-transitional", "xhtml-1.1-basic", and "html-5.0", among others. For more information about HTML doctype declarations, see the W3C specifications. -- Documentation for apex:page docType attribute

I'd love to develop my Visualforce in HTML5, but we're using a lot of standard Salesforce styling and formatting. Does the SFDC styling perform well under HTML5? Are there bugs, errors, or strange behaviors you've noticed?

share|improve this question
1  
one of the links point to rendering issues : salesforce.stackexchange.com/questions/282/…!!! –  rao Nov 21 '12 at 22:29
    
I played around with this a little while ago and wrote up some things here: laceysnr.com/2011/08/html-5-experiments-adventures-in.html - not sure if it'll be of any use to you or even how accurate it is! –  LaceySnr Nov 21 '12 at 23:27

1 Answer 1

I haven't noticed anything amiss when using the HTML5 doctype. The whole reason was chosen in the first place is because it was the simplest doctype that would be rendered by browsers in standards mode. This means that html4 markup will display fine under html5. This does not mean that all will be rosy trying to get visualforce to play nicely with html5, as one of the links in your comments illustrate.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.