input textarea 限制输入
2015-07-09 10:56
253 查看
textarea 限制输入:
<textarea maxlength="60" onchange="this.value=this.value.substring(0, 60)" onkeydown="this.value=this.value.substring(0, 60)" onkeyup="this.value=this.value.substring(0, 60)" id="content" name="content" style="width:300px;" >${bc.content}</textarea>
input 数字输入:
<input id="startpoint" name="startpoint" style="width:100px;"
onChange="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')"/>
input 虽控制长度,但表单提交时没有
<input class="easyui-validatebox" required="true" type="text"
id="themetitle" validType="length[1,16]" name="title"
style="width: 65%" value="" />
<textarea maxlength="60" onchange="this.value=this.value.substring(0, 60)" onkeydown="this.value=this.value.substring(0, 60)" onkeyup="this.value=this.value.substring(0, 60)" id="content" name="content" style="width:300px;" >${bc.content}</textarea>
input 数字输入:
<input id="startpoint" name="startpoint" style="width:100px;"
onChange="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')"/>
input 虽控制长度,但表单提交时没有
<input class="easyui-validatebox" required="true" type="text"
id="themetitle" validType="length[1,16]" name="title"
style="width: 65%" value="" />
相关文章推荐
- PHP没有数据库连接池怎么破?PHP环境下使用Nginx ngx_http_limit_req_module模块的高负载解决方案
- MongoDB快速入门教程
- Interlocked Variable Access
- mysql 存储过程
- 简述PXE+DHCP+TFTP+KS无人值守批量装机
- Mysql JDBC URL中几个重要参数说明
- GRE写作必备句型
- Unable to execute dex: Multiple dex files define Landroid/support/annotation/AnimRes
- jquery 字符串转换为数值
- onmouseover事件中把鼠标变成小手形状
- fpga该驱动器调试dev_dbg 无输出
- DOM的addEventListener函数一个陷阱。
- MVC C# 直接导出txt文件
- MSP430F149学习之路——时钟1
- The state of Web Components
- 053第471题
- Google Volley 解析参考文章
- VMX学习-VMX Non-Root Operation
- 用swift创建第一个控件UILabel
- Android入门(41)——第三章:使用Toast动态显示信息