Side navigation
Ticket #4237: labilbe.html
File labilbe.html, 1.6 KB (added by labilbe, February 24, 2009 11:57PM UTC)
The Html file to reproduce the behavior
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>jQuery validation plug-in - main demo</title>
<link rel="stylesheet" type="text/css" media="screen" href="css/screen.css" />
<script src="../lib/jquery.js" type="text/javascript"></script>
<script src="../jquery.validate.js" type="text/javascript"></script>
<style type="text/css">
div#error {
border: solid red;
display: none;
}
</style>
</head>
<body>
<script type="text/javascript">
$().ready(function() {
$("#toto").validate({
errorLabelContainer: $("#error"),
rules: {
test: {
required: false,
minlength: 2
}
},
messages: {
test: {
minlength: "Your username must consist of at least 2 characters"
}
}
});
});
</script>
<form id="toto" method="get" action="">
<p>
<input type="text" id="test" name="test" />
<button type="submit">Send</button>
</p>
</form>
<div id="error">
</div>
<p>
<ul>
<li>The input text accepts at least 2 characters</li>
<li>To reproduce the bug, input one character</li>
<li>Then blur the input type text</li>
<li>A message must appear "Your username must consist of at least 2 characters"</li>
<li>Focus on the input type text</li>
<li>Remove the text</li>
<li>And blur it again</li>
<li>The container should remain visible (without any text) <-- BUG</li>
</ul>
</p>
</body>
</html>
Download in other formats:
Original Format
File labilbe.html, 1.6 KB (added by labilbe, February 24, 2009 11:57PM UTC)
The Html file to reproduce the behavior
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>jQuery validation plug-in - main demo</title>
<link rel="stylesheet" type="text/css" media="screen" href="css/screen.css" />
<script src="../lib/jquery.js" type="text/javascript"></script>
<script src="../jquery.validate.js" type="text/javascript"></script>
<style type="text/css">
div#error {
border: solid red;
display: none;
}
</style>
</head>
<body>
<script type="text/javascript">
$().ready(function() {
$("#toto").validate({
errorLabelContainer: $("#error"),
rules: {
test: {
required: false,
minlength: 2
}
},
messages: {
test: {
minlength: "Your username must consist of at least 2 characters"
}
}
});
});
</script>
<form id="toto" method="get" action="">
<p>
<input type="text" id="test" name="test" />
<button type="submit">Send</button>
</p>
</form>
<div id="error">
</div>
<p>
<ul>
<li>The input text accepts at least 2 characters</li>
<li>To reproduce the bug, input one character</li>
<li>Then blur the input type text</li>
<li>A message must appear "Your username must consist of at least 2 characters"</li>
<li>Focus on the input type text</li>
<li>Remove the text</li>
<li>And blur it again</li>
<li>The container should remain visible (without any text) <-- BUG</li>
</ul>
</p>
</body>
</html>