开发者

What is the minimum doctype IE requires to NOT use quirks mode?

I am developing fo开发者_开发百科r SharePoint 2007 and my pretty code is being broken, presumably by code SharePoint generates around my Content Editor web-part. My understanding is, because there is no "top level" doctype declaration made before SharePoint sends the code to the browser, Internet Explorer is forced to render the page in quirks mode. Thus, the entire page is rendered without respecting certain CSS declarations and my page looks wrong.

I have hopes of convincing the powers that be that this issue is worth fixing, but I figure I need to be able to tell them what I want...

So, what doctype would work best when I'm writing in XHTML (strict) with CSS2 but the stuff surrounding my code is not strict?


<!DOCTYPE html>

This declares your document as HTML5, and HTML5 clearly defines how browsers should handle broken code so your result should look the same on all browsers.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜