实例代码“Ctrl+/”提示“F11/ESC”全屏 返回 格式化 恢复 运行
x
 
1
<!DOCTYPE html>
2
<html>
3
<body>
4
5
<form action="demo-form.php" method="get" id="nameform">
6
First name: <input type="text" name="fname" /><br>
7
Last name: <input type="text" name="lname" /><br>
8
</form>
9
10
<p>The button below is outside the form element, but still part of the form.</p>
11
12
<button type="submit" form="nameform" value="Submit">Submit</button>
13
14
<p><b>Note:</b> The form attribute does not work in IE.</p>
15
16
</body>
17
</html>
18