Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to handle reset behaviour when escape character is pressed twice in Orbeon Xforms

I have come to know that from IE 5, there is a strange behaviour that when escape character is pressed twice, all the form fields are reset automatically. This is not occuring in Mozilla. So as a remedy i have put a simple javascript that will alert user when values are getting reset. Below is the code for it.

<html>
<body>
<form action="Enroll" method="post" onreset="return confirm('Really reset all form  fields?')">
<table>
<tr>
<td>Name </td>
<td><input type="text" id="name"/></td>
<td>Id </td>
<td><input type="text" id="id"/></td>
</tr>
<tr>
<td><input type="submit" value="Submit"></td>
</tr>
</table>
</form>
</body>
</html>

Now, please help me how i can acheive this is Orbeon Xforms as this is happening in Orbeon xforms also.

like image 999
Jayy Avatar asked Oct 10 '22 04:10

Jayy


1 Answers

This used to be a bug, and it has been fixed on 2012-04-20, and the fix is available in nightly builds and releases made after that date.

like image 135
avernet Avatar answered Oct 17 '22 22:10

avernet