By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,401 Members | 1,381 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,401 IT Pros & Developers. It's quick & easy.

Javascript, Localhost and IE8 Issues

P: 2
I've been developing a content management system over the past 5 months. Recently I began implementing AJAX and other misc. javascript into some pages.

I was mainly developing and debugging using Firefox and Chrome (because my IE 7 stopped working ;-D about a year ago). I'm running a WAMP server on Windows XP, and view my site through http://localhost . Everything is fine and dandy.

So today, I go on a browser binge (because my CMS is almost complete) to test compatibility and display (XHTML 1.0 Transitional). I tested and viewed my site in FF 3.0, Chrome Beta, Opera 9.6, Safari 3.2. I also downloaded the new IE 8, and was surprised at how well it ran and rendered my CMS, and tweaked my layout a bit to display perfect across all of them.

One major problem: IE 8 won't run my javascript. I searched for hours online trying to figure out if it was a "localhost" issue, but because I've been out of the IE loop for the last year, I couldn't find anything that actually helped.

For reference: The javascript I am using between the old and new version of the CMS works fine in IE 8 (that is, if I go to the live version, it loads up fine). The rest of the javascript is mainly AJAX and stored in separate .js files. Inline JS [e.g. javascript:alert(1) ] code works fine for "localhost" in IE 8, but otherwise I get nasty "Object Expected" errors. I want to test these AJAX applications in IE8 because most of the folks that are going to be using this CMS will most likely be using IE8.

Anyone have any ideas regarding this matter? Thanks.
Mar 22 '09 #1
Share this Question
Share on Google+
3 Replies


P: 2
I figured it out.

I was so ingrained in developing to the highest web standards possible, that it didn't even strike me at first, but after researching down this path a bit, I now see the error in my ways. IE 8 does not (and supposedly will not) support the MIMETYPE [ type="application/javascript" ] , so none of the javascript was being included. I switched the javascript type to [ type="text/javascript" ] and everything works like it's supposed to.

Go figure, a day pulling my hair out for something that petty. Damn you Microsoft.
Mar 23 '09 #2

Frinavale
Expert Mod 5K+
P: 9,731
I'm really glad you shared your solution.
I'm sure it's going to save other people the same problem in the future.

Thanks,

-Frinny
Mar 24 '09 #3

drhowarddrfine
Expert 5K+
P: 7,435
It doesn't support XHTML either.
Mar 25 '09 #4

Post your reply

Sign in to post your reply or Sign up for a free account.