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

IE demos don't work in IE8 standards mode #2

Open
eug48 opened this issue Dec 11, 2013 · 7 comments
Open

IE demos don't work in IE8 standards mode #2

eug48 opened this issue Dec 11, 2013 · 7 comments

Comments

@eug48
Copy link

eug48 commented Dec 11, 2013

No description provided.

@kbjr
Copy link
Member

kbjr commented Dec 11, 2013

I'll take a look.
On Dec 11, 2013 3:54 AM, "eug48" [email protected] wrote:


Reply to this email directly or view it on GitHubhttps://github.com//issues/2
.

@kbjr
Copy link
Member

kbjr commented Dec 13, 2013

Hmm... there doesn't seem to be any error thrown, it looks like the CSS behavior isn't being applied correctly. It does work if you change IE8 to compat mode or if its running in IE7 mode, so I would assume it has something to do with IE trying to be "correct" and ignoring the behavior added.

Oh, wait, now that I think about it I'm pretty sure IE8 is when they started using -ms-behavior, I probably will have to add support for that...

@kbjr
Copy link
Member

kbjr commented Dec 13, 2013

After some research, I figured out the problem. IE8+ (only standard mode) no longer supports expressions, which is how the CSS behaviors are calling to the polyfill:

behavior: expression(document.placeholderPolyfill(this));

The only solution to this would be to switch to using an .htc file, which is something I really didn't/don't want to do (I would really prefer to limit the requirements to a single file). I might come up with a cleaver solution, but in the mean time, there are a couple of options for you.

  • You can make IE8 use compatibility mode, which is ugly.
  • You can write a tiny .htc file that looks something like below and change the source to use the .htc file instead of the expression.
<public:component>
<script type="text/javascript">
    window.document.placeholderPolyfill(element);
</script>
</public:component>
  • Or, just use the standard placeholder and load it with a conditional comment to limit it to IE.

If you want to go with the .htc solution that uses a second file, I can write you a custom build, shouldn't take too long.

@eug48
Copy link
Author

eug48 commented Dec 26, 2013

Thanks! Sorry for the long delay, I just managed to get back to this and used that tiny .htc file with ie-behavior.js. It works - http://www.healthyachievements.org/staging/index.html

Now IE8 compat mode was broken though, so I just added the IE=edge meta tag to disable it.

@kbjr
Copy link
Member

kbjr commented Dec 26, 2013

Alright, I'm going to leave this open until I decide how I want to go about dealing with this on a more permanent basis.

@entozoon
Copy link

The demos seem to work fine for me in IE8 - IE8 standards mode running on XP.
However, only for type="text" .. type="password" doesn't do anything.

@TotzkePaul
Copy link

I have this issue in IE11 - IE8 mode but I will just use the simple.js as that works.

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

4 participants