User blog comment:Ohmyn0/Making your wiki HTML5 compliant/@comment-34115-20120712042029/@comment-34115-20120808041355

@TK-999


 * facepalm*

You did read my post, right?

"The only exception to this is quirks-mode which is enabled in certain circumstances and has nothing to do with standards."

Quirks-mode/Almost-Standards-mode/Standards-mode comes from the history of incompatible implementations of HTML. The days before browsers all tried to conform to an aggreed-uppon standard.

Any good standard DOCTYPE will take the browser out of quirks mode. It doesn't matter if a DOCTYPE is HTML4, XHTML, or HTML5. All the browser cares about is that it sees a DOCTYPE that doesn't make it think it's looking at a webpage written in the 90s. After that it doesn't give a shit what you put in PUBLIC to tell what the markup version is. And naturally quirks mode is just a hint used for things like what box-model to use in css. It has nothing to do with the markup rules the browser follows.

Browsers also don't give a shit whether you say your document is XHTML or not inside the DOCTYPE. No matter what you say in the doctype, if you send your content with the text/html mimetype then the browser will use their one single html parser to parse the markup. They will never parse it as XHTML unless you use application/xhtml+xml, which of course will throw IE into a fit.

This fact of course is completely irrelevant to the discussion. Because we're not talking about XML vs. HTML parsing. We're talking about what set of rules the browser follows. ie: What markup standard the rules for the support of different elements, attributes, etc... are. And for that no matter what version you say you're using the browser always ignores you and and follows the last version of HTML5 (aka HTML) that the devs looked at and worked on implementing. Naturally you can see this fact by noting that when you put a tag inside of a page with a HTML4 or XHTML1.0 doctype it still works.

Oh btw... this also means that XHTML1.1 vs. HTML5 is pointless... Because even when you use application/xhtml+xml the browser doesn't treat it as XHTML1.1, ;) it treats it as XHTML5.

Also btw, HTML5 supports RDFa.

And as for the deprecated attribute stuff in the code. It does switch handling based on the element. // Skip if this attribute is not relevant to this element if ( !in_array( $element, $elements ) ) {