Reputation: 8699
I have a simple HTML form that will not submit in IE9. It works in Chrome, FF, and IE10.
I have tried to submit in IE9 on Windows 7 and IE10 on Windows 8.
IE10 works unless I change the browser mode to IE9; then it won't submit.
Demo. If you click "Save" on any working browser, it'll take you to the fake demo_form.asp.
Here is the form:
<!DOCTYPE html>
<html>
<head>
<title>Title</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.css" />
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.js"></script>
</head>
<body>
<div data-role="page">
<div data-role="header">
<h1>Title</h1>
</div>
<div data-role="fieldcontain">
<div class="error-messsage">
<p/>
</div>
<p>
<form action="demo_form.asp" data-ajax="false" method="get">
<input type="hidden" name="scoreType" id="_scoreType" value="T"/>
<div data-role="fieldcontain">
<fieldset class="ui-grid-a">
<div class="ui-block-a">Minutes:</div>
<div class="ui-block-b">Seconds:</div>
<div class="ui-block-a">
<input type="number" name="score_minutes" value="1" id="_scoreMinutes" maxlength="20" autocomplete="off" data-inline="true"/>
</div>
<div class="ui-block-b">
<input type="number" name="score_seconds" value="2" id="_scoreSeconds" maxlength="20" autocomplete="off" data-inline="true"/>
</div>
</fieldset>
<input type="hidden" name="score" id="_score" value="62"/>
</div>
<div data-role="fieldcontain">
<label for="_note">Note:</label>
<textarea name="note" cols="40" rows="10" id="_note" autocomplete="off"/>
</div>
<div data-role="fieldcontain">
<label for="_classAttended" class="select">Class Time:</label>
<select name="class_attended" id="_classAttended" data-native-menu="false">
<option value="-1"/>
<option value="6">06:00 am</option>>
</select>
</div>
<div data-role="fieldcontain">
<label for="_memberRating" class="select">Member Rating:</label>
<select name="member_rating" id="_memberRating" data-native-menu="false">
<option value="-1"/>
<option value="5">5 </option>
</select>
</div>
<div data-role="fieldcontain">
<label for="_rx">RX</label>
<input type="checkbox" name="rx" value="1" id="_rx" data-mini="true"/>
</div>
<div data-role="fieldcontain">
<a href="http://mysite.com/index.php/welcome/index/TRUE" data-ajax="false" data-role="button" data-inline="true">Cancel</a>
<button name="" type="Submit" id="_submit" class="ui-btn-hidden" value="Save" aria-disabled="false" data-inline="true" data-theme="b"/>
</div>
</form>
</p>
</div>
</div>
</body>
</html>
Upvotes: 0
Views: 1347
Reputation: 83006
You have a <div>
that's trying to be inside a <form>
that's inside a <p>
. But <div>
s can't be inside a <p>
, so the HTML parser closes the <p>
element, and in doing so also closes the <form>
. So the save button is not inside the form, and in consequence IE9 doesn't know what to submit when you click the button. Remove the <p>
tags that surround the <form>
.
The HTML5 parser as used in FF, Chrome and IE10 has some nifty tricks to cope with your invalid markup, but the older IE9 parser cannot cope.
Also, you have <p/>
and <textarea/>
. Don't do that. Self closing syntax is not supported for either element.
Upvotes: 5