It’s just data

Minimalist Markup, now text/html Compatible

Bug 311366 is resolved in Firefox 3.0.1.  It may, in fact, have been fixed earlier; but my initial testing was flawed.  Thanks go out to Anne van Kesteren and James Graham for spotting the problem that was preventing me from seeing that it was fixed.

Demonstration of an minimalist HTML5 page served as text/html.


This was fixed just before Firefox 3 b5.
If you want to serve HTML5 accordingly, you can use this code to serve application/xhtml+xml only to users pre Firefox 3b5:

<?php
header ("Content-type: ".(
preg_match ('/\bGecko\/(\d{10})\b/', $SERVER['HTTP_USER_AGENT'], $)
? ((int) $_[1] < 2008032619 ? ‘application/xhtml+xml’ : ‘text/html') : 'text/html’
));
?>

If, however, you use a legend tag inside a figure tag (as per HTML5), you will need to serve as application/xhtml+xml regardless, otherwise firefox will insert an implicit fieldset tag into the document, breaking things. Safari also chokes on HTML5 use of the legend tag, unless served as xml.

Posted by Kroc Camen at

Ping! “Minimalist” Is Not The Right Word

Posted by Kroc Camen at

Add your comment