jQuery Form Plugin not Working in IE
Hi,
I've set up a simple form that validates then submits via Ajax using the jQuery Form Plugin by malsup. Everything is working now in FF, Chrome and Safari but it doesn't work in IE (7). I have no idea what could be causing the problem. My relevant code includes:
EDIT: I've just tried it out in Opera 10.6 and I get the same lack of functionality. Any ideas?
my javascript:
-
$('#mt_survey').submit(function() {
if ( $("#mt_survey").valid() == true) {
$(this).ajaxSubmit({
target: '#messages',
success: function() {
$('#messages').fadeIn('slow');
}});
$( 'html, body' ).animate( { scrollTop: 0 }, "slow" );
}
return false;
});
my form:
- <form action="/php/survey_submit.php" id="mt_survey" name="mt_survey" method="post";>
- ...
- ...
- </form>
my php file:
- <?php
- $case_num = $_POST['case_num'];
- $position = $_POST['position'];
- ....
- ?>
Any ideas? Thanks for your help.
Edit: I should be more precise when I say it's not working in IE. When I click the submit button it runs the submit event, including the page scroll (which works). But all the $_POST's in the php file return null values. If I replace the ".ajaxSubmit()" with a "return true;" the normal submit event fires and everything works, but obviously without the ajax, which I need..