- This topic is empty.
May 18, 2012 at 10:37 am #38125almcrorieParticipant
went to github, and checked out respond.js, demo worked fine on IE8, no problem with Chrome or FF.
downloaded the code, ran test html on IE8, no go, media queries do not work with IE8, the html test code just does not work the same as the demo code on the same pc.
anyone get respond.js test html included in the download working in IE8?? what is different between the online demo code and the download html test code?
would like to revamp the web site I look after for the newer smaller screen sizes but running into this problem with IE8. IE8 is the most popular browser version used on this website, so anything like this needs to work with IE8.
AlMay 19, 2012 at 10:09 am #103097almcrorieParticipant
apparently respond.js must be run on a web server, it will not run locally, this was noted in the github documentation
AlJune 21, 2013 at 7:20 am #139721Kushal JayswalParticipant
I have tried this and earlier it was working but after some days when I checked again, it’s stopped working and giving error.June 21, 2013 at 10:23 am #139755jonathansampsonMember
@almcrorie, you’re absolutely correct. The statement from the documentation delcaring this follows:
> Due to security restrictions, some browsers may not allow this script to work on file:// urls (because it uses xmlHttpRequest). Run it on a web server.
That being said, there are many options for developers locally. You could run MAMP, WAMP, enable IIS on your Windows machine, run the Python Simple Server, or even the built-in web server that ships with PHP.
If non of those options sound appealing, you can simply permit your browser to allow scripts on the file protocol. In Chrome, you can run the browser with the –allow-file-access-from-files flag. Internet Explorer, traditionally, would allow file access from the file protocol when you used ActiveXObject to issue the request, but not for XMLHttpRequest. jQuery would use ActiveXObject when it was present, but this isn’t the case with IE10, I don’t believe.
Another alternative is to use a different solution: Scott Jehl makes reference to one in the bottom of his README –[css3.mediaqueries.js](https://code.google.com/p/css3-mediaqueries-js/).
- The forum ‘Other’ is closed to new topics and replies.