2013年12月16日星期一

How jsp page opens IE10 compatibility mode

Online said in jsp inside with :
can open IE 's compatibility mode , but when I tried to find that the addition of this line of code after the button is only compatible with the IE address bar hidden,
does not really turn on compatibility mode. Which Daniel has a solution.
------ Solution ---------------------------------------- ----
<meta http-equiv="X-UA-Compatible" content="IE=7" />

------ Solution ------------------------------ --------------
this sentence means that documents not in accordance with IE7 IE7 mode parse the document but did not know if you can solve What is the problem not solved
------ Solution ---------------------------------- ----------
compatible browser is nothing more than tune css styles compatible
------ Solution ------------ --------------------------------
using the X-UA-Compatible header to specify your page support IE versions. Use document.documentMode determine compatibility mode page .
If you want to determine whether a file using JavaScript compatibility mode , following the introduction of this code example to support older versions of IE.

engine = null;
if (window.navigator.appName == "Microsoft Internet Explorer")
{
/ / This is an IE browser. What mode is the engine in?
if (document.documentMode) / / IE8
engine = document.documentMode;
else / / IE 5-7
{
engine = 5; / / Assume quirks mode unless proven otherwise
if (document.compatMode)
{
if (document.compatMode == "CSS1Compat")
engine = 7; / / standards mode
}
}
/ / the engine variable now contains the document compatibility mode.
}

Recognizing the value of the content attribute


content attribute value when receiving the values ​​are different from the previously described flexible . This enables you to IE how to display your pages more manipulative . For example, you can set the content attribute value IE = 7.5. When you do it , IE attempts to convert the value to version vector and selects the closest results. In this example , IE will set it to IE7 mode. The following example shows the status of the mode is set to other values ​​.

<-! IE5 mode - - >
<-! IE7 mode ->
<-! IE8 mode ->
<-! IE5 mode - - >

<-! This header mimics Internet Explorer 7 and uses
to determine how to display the Web page ->

Note : The preceding example shows the contents of a single value . IE will actually run the page in the first X-UA-Compatible header.

You can also use the content attribute to specify complex file compatibility mode, which can help ensure that your web browser versions in the future can be a consistent display . To set the plural file mode , set the Content property to determine the mode you want to use . Use a semicolon to separate each mode .

If a specific version of IE compatibility mode required to support more than one , will use the properties listed in the header of the highest content available modes . You can use this feature to exclude specific compatibility mode, although not recommended to do so. For example, the following header that would exclude IE7 mode.




------ For reference only ---------------------------------- -----
added a phrase that is compatible with the button just hide it, did not really set IE7 compatibility mode
------ For reference only -------- -------------------------------

plus plus this one did not have the same effect , in addition to a compatible that button is hidden.
If I click on compatibility, it would have an effect .
------ For reference only -------------------------------------- -
ask your question solved? I now have the same problem. qq: 756535761

没有评论:

发表评论