Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Login: Internet Explorer 11 triggers compatibility view for "intranet" sites, breaking Cockpit #9269

Closed
garrett opened this issue May 30, 2018 · 7 comments

Comments

@garrett
Copy link
Member

garrett commented May 30, 2018

Internet Explorer 11 on Windows 10, by default, switches to "compatibility view" (aka: IE7+ActiveX rendering) for sites it detects as behind the firewall (what it calls "intranet").

As Cockpit does not work on IE7 (just like most websites at this point in time), It's not even possible to log in to Cockpit. The form does not even appear.


Screenshot of IE7 mode, automatically triggered by default:

ie7-broken

Screenshot of the compatibility view settings (click the gear icon, then select "Compatibility View settings"):

compatibility-view

@garrett
Copy link
Member Author

garrett commented May 30, 2018

Issue discovered in #9243 (comment)

@garrett
Copy link
Member Author

garrett commented May 30, 2018

Supposed fix is typically adding the following meta tag as the very first tag under (with the exception of <title>, which can come before it):

<meta http-equiv="X-UA-Compatible" content="IE=Edge">

However, <!DOCTYPE html> is supposed to be enough in IE11, and we're using it already.

@garrett
Copy link
Member Author

garrett commented May 30, 2018

A workaround was to use a FQDN instead of just the short hostname. In my case, I just added .lan and things worked as expected.

This means anyone using Windows and IE11 to administer a Linux system with Cockpit must use the full hostname. Short names, even if they're resolved perfectly fine, won't work properly in Internet Explorer.

(I think this is yet-another papercut issue that says we should drop all IE support at sometime in the near future.)

@garrett
Copy link
Member Author

garrett commented May 30, 2018

Solutions

  1. Try the meta tag in our HTML and see what IE11 does when a short hostname is used.
  2. Provide a fallback message to those using IE, making it clear what the problem is, and what a solution could be. (Upgrade browser, switch out of compatibility mode (with instructions), etc.)

Info on how to target Internet Explorer

Show something to just Internet Explorer (I'm pretty sure this excludes Edge, which is a different browser really):

<!--[if IE]>
Only IE sees this
<![endif]-->

Target IE 10 and lower:

<!--[if lt IE 11]>
Versions of IE less than 11 see this.
<![endif]-->

Target IE 7 (I believe this includes compatibility mode of IE11):

<!--[if IE 7]>
Only IE 7 sees this.
<![endif]-->

@garrett
Copy link
Member Author

garrett commented May 30, 2018

That info on Internet Explorer supporting conditional comments? Out of date. IE10 and IE11 do not support conditional comments anymore — not even in old-IE emulation mode ("compatibility view").

🤷‍♂️

@garrett
Copy link
Member Author

garrett commented May 30, 2018

Interestingly enough, CSS feature queries (@supports) works in everything but IE:
https://caniuse.com/#feat=css-featurequeries

However, this doesn't help us with supporting IE11 and nothing lower. It would help us whenever we do decide to drop IE11.

@garrett garrett changed the title Internet Explorer 11 triggers compatibility view for "intranet" sites, breaking Cockpit Login: Internet Explorer 11 triggers compatibility view for "intranet" sites, breaking Cockpit Jun 20, 2018
@garrett
Copy link
Member Author

garrett commented Nov 12, 2018

We "fixed" this by deprecating IE in #9689.

People using Internet Explorer should upgrade to Edge or use a standards compliant browser like Firefox or Chrome.

@garrett garrett closed this as completed Nov 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant