Вопрос

I'm having a problem with my css, view in IE compatibility mode.

For example

div#tab-bar-selected{
    border-top-left-radius:5px;
    border-top-right-radius:0;
    border-bottom-right-radius:0;
    border-bottom-left-radius:5px;
}

the border is not rounded, it's not just border-radius, vertical-align:midle, and most of CSS3 are not working, this issue not occured if I do the 2 following thing

  1. remove my site from compatibility view setting or
  2. put meta tag <meta http-equiv="X-UA-Compatible" content="IE=edge"> inside html file.

But I'm required to put my site in compatibility view setting because there is a function required to trigger vbscript. If I do the two step mention above, the browser will not recognize vbscript function / the function is undefined.

the following are the vbscript

sub launchBarcode()
    Dim appShell
    Set appShell = CreateObject("WScript.Shell")
        Set WshUserEnv=appShell.Environment("System")
        Dim program

        'Waited for you to close the window before it continued.
        appShell.Run WshUserEnv("ilms02") & "\\BarcodeReader\\BarcodeReader.exe",1,True

        appShell.SendKeys "{F5}"
    Set appShell = Nothing
end sub

How can I let IE recognize the vbscript function without damaging the CSS.

Hope somebody can provide some solution.

I'm using IE11

Это было полезно?

Решение

You shouldn't use VBScript nowadays.

As of Internet Explorer 11, VBScript is considered deprecated and should no longer be used as a scripting language for IE11. Webpages displayed in IE11 edge mode won't execute VBScript code in the Internet zone. VBScript is supported for webpages displayed in other security zones.

For compatibility reasons, VBScript does execute for legacy document modes (IE10 standards mode and earlier), however, this should be considered a temporary solution. VBScript is available to webpages displayed in other security zones.

source

You can try using this:

<meta http-equiv="x-ua-compatible" content="IE=10,9" >
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top