0

The website in question is cpavalet.com

My javascript loads fine on all browsers except ie7 and ie8. For a few hours now I have been trying to debug the issue to no avail.

I am using jQuery and modernizr, and using the supersized library for the full-sized background images.

The weird thing is, sometimes when I load the page it loads correctly, other times the javascript doesn't work on the page. I think it has to do with the order the scripts are loaded. I am using document.ready for my jquery scripts.

Can anyone shed some light as to why it's not working correctly in ie7 and ie8? I am currently using ie8 for testing purposes.

I am using javascript for: image slider on home page, full-size background images, back to top link to slide to the top, and form validation.

Thanks!

Corey

4
  • Using the developer tools in ie9, I switched to ie7 and ie8 browser modes and it worked just fine with no errors. What errors are you getting? What doesn't work? Commented Jan 12, 2012 at 22:24
  • Works for me as well. However, you state that you're using modernizr, (I see that it's loading, but you never make use of it.) Commented Jan 12, 2012 at 22:28
  • I am using modernizr to add different css styles based off of of browser features. As far as the error, I don't see an error either. If you use the developer tools in ie9, switch the document mode to ie7 or ie8. Sometimes you have to refresh the page a couple of times for the error. Bascially, no javascript works. The background doesn't load, the back to top button breaks, and the form's js doesn't work. Commented Jan 12, 2012 at 23:36
  • You comment "Basically, no javascript works," sounds a bit like an exception is being thrown and quietly ignored. Have you used the developer tools debugger to check for that possibility? Commented Jan 13, 2012 at 16:22

1 Answer 1

1

My guess as to why it wasn't loading correctly was partly correct. I thought that it was because of the order I had my scripts being run on the page.

The answer is that I was using the defer attribute when loading my scripts. When I removed the defer attributes, the scripts started working correctly again.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.