一个模仿HTML5功能的jquery控件
placeholder的作用是,当你在文本框没输入任何东西,时,
会自动光标停留在文本框中
2)EMAIL
<input type="email" name="email" id="email"/>
3)TEXTAREA
? <textarea maxlength="60" name="comment" id="comment"/>
4) URL
? <input type="url" name="website" placeholder="http://"/>
这个表明必须输入的是url
? 使用这个控件
<script>
???
??? $('#myform').html5form({
???????
??????? async : false, // cancels the default submit method.
??????? method : 'GET', // changes the request method.
??????? action : 'respuesta.php', // changes the action method.
??????? responseDiv : '#respuesta' // a content div to get the callback function response.
???????
??? })
???
</script>
5 当有多个form时
<script>
??? $('#myform_one').html5form({
??????? method: 'POST',
??? });
??? $('#myform_two').html5form({
??????? method: 'GET'
??? });
</script>
支持所有浏览器:
<script>
??? $('#myform').html5form({
??????? allBrowsers: true
??? });
</script>
下载见:
http://html5form.googlecode.com/svn/trunk/jquery.html5form-min.js