What could be causing Javascript to stop working in IE in Strict mode [closed]
I'm trying to debug my jQuery plugin and it worked fine in IE until I added <!doctype html>
. It still works fine in all browsers except IE sigh (tested in 6,7,8). What sort of thing could be causing this?
here is the page: http://liime.net/projects/liimeBar/demo.html
Your condition in constructScrollers() window.innerHeight < $('body')[0].scrollHeight is false, bacause both values are the same in IE8. So no scrollers are created
Do some research in jQuery that you find the proper function how to get the heights you want to test.
You have much code in it, that could be better if you used more jQuery functions, not just the selectors.
--edit try this instead $(window).height() < $('body').height()
P.S.: By this script you can only make a scrollbar for the body, because you hard coded the body. try $(this) instead, which is the object you called your liimebar() function with and don't use ids on liimebar_buttons, ..bar etc, but classes, so you could possibly have more than on scrollbar.
精彩评论