本教程操作环境:windows10系统、html5版、dell g3电脑。
html5中text是什么意思
type 属性规定要显示的元素的类型。默认类型是:text。
默认text表示的是:
定义一个单行的文本字段(默认宽度为 20 个字符)。
语法如下:
<元素 type="text">
示例如下:
<!doctype html><html><head> <meta charset="utf-8"> <title>123</title> </head><body><form action="demo-form.php"> first name: <input type="text" name="fname"><br> last name: <input type="text" name="lname"><br> <input type="submit"></form><p>点击提交按钮提交表单。</p></body></html>
输出结果:
推荐教程:《html视频教程》
以上就是html5中text是什么意思的详细内容。
