Joshua Jarman
Joshua Jarman

Reputation:

prototype.js 1.6.0.3 Ajax.Updater not working in IE7 or IE8

This works on all other browsers...but fails on IE7 & IE8.

<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<script src="/javascripts/prototype.js" type="text/javascript" charset="utf-8"></script>
</head>
<body>
<input type="button" value="Ajax Test" onclick="var myAjax = new Ajax.Updater('TestContent', '/store/home', {method: 'post', parameters: 'foo=bar'});" />
<div id="TestContent" style="margin: 100px; border: 1px solid #F00; height: 500px;">
</div>
</body>
</html>

Upvotes: -1

Views: 4637

Answers (3)

Cameron Maxwell
Cameron Maxwell

Reputation: 1

I had a similar problem.

It turns out that in my case, the ajax response had a FORM element in it, and the destination of the updater was already inside a FORM element.

It worked fine in firefox, but not IE.

link text

Upvotes: 0

Joshua Jarman
Joshua Jarman

Reputation:

removed all utf-8 references and suddenly IE decides to play ball. IE, even the brand new version 8, is years behind the other 3 (Firefox, Safari, Opera)... oh well.

Upvotes: 1

Stefan Lundstr&#246;m
Stefan Lundstr&#246;m

Reputation: 1302

Syntax looks ok. Maybe the variable assignment isnt allowed or causing the variable to be deleted before its complete. Have you tried with creating the Updater in an external function?

Upvotes: 0

Related Questions