I am using yepnope to load my scripts, but when using IE7, it won't fire the Mootools domready OR load events if they have already been fired. Any idea why?
Here is the code.
yepnope([
{
load: "/js/uncompressed/mootools.js",
callback: function () {
if (Browser.ie && Browser.version.toFloat() < 8) {
yepnope([
{
开发者_如何学编程 load: "/js/uncompressed/ie.js",
complete: function () {
window.addEvent("domready", function () {
setupForIE();
});
}
}
]);
}
}
}
]);
Using MooTools version 1.3.2 (no compat) and yepnope bundled with Modernizr.
After more testing, it seems that IE9 and IE8 aren't firing the domready either.
Because you are loading Mootools "Asyncronously", maybe the js-Library loading after the DOMContentLoaded
- event has already fired, thus your function not got executed.
精彩评论