<!DOCTYPE HTML>
<html>
<head>
<title> </title>
</head>
<script type="text/javascript">
function changeInputlength(cursor)
{
cursor.size=cursor.value.length+2;
}
</script>
<body>
<input type="text" size="5" id="text" onkeydown="changeInputlength(this);" style="padding: 0px 8px"/>
</body>
</html>
js input 长度 输入框动态
最新推荐文章于 2022-02-24 15:57:14 发布