Controlling default rendering (Internet Explorer) (original) (raw)


Share via


As discussed in Defining document compatibility, Windows Internet Explorer uses the directive to determine how to interpret and display a webpage. If a page doesn't contain a directive, Internet Explorer displays the page in quirks mode by default.

While this is true, it generally applies to webpages open in the Internet zone. Pages opened in the Intranet zone might be treated differently, depending on the configuration of the browser, the presence of group policy options, and other factors. We describe these factors and explain how you can control the default rendering of pages that do not contain directives.

Note For best results, use directives in all webpages. This not only helps validate the webpage, it also ensures that the page works effectively in all browsers, devices, and experiences. For more info, see How to Enable Standards Support.

If the directive specifies a standards-based document type, Internet Explorer displays the page in standards mode. The HTML5 document type is a standards-based document type and is declared as shown in this example.

<!DOCTYPE html> 

If the directive is missing or doesn't specify a standards-based document type, Internet Explorer displays the page in quirks mode by default.

Be aware that certain conditions, like those listed here, can force Internet Explorer to display pages in a document compatibility mode different from the one specified in the webpage.

These links provide additional info that describes how Internet Explorer determines the appropriate document mode for a webpage:

Note When configured to load Intranet pages in Compatibility View, Internet Explorer makes an exception for pages loaded using the localhost address or a loopback address. Pages loaded using one of these techniques are displayed in standards mode when the directive specifies a standards-based document type.

In addition, Internet Explorer supports a feature control that allows you to control the way the browser handles webpages that don't contain X-UA-Compatible headers. For more info, see the Browser Emulation feature control.