安科网
源代码:
点击运行
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>安科教程(www.ancii.com)</title> </head> <body> <form action="demo-form.php" method="get"> <fieldset name="personalia"> 姓名: <input type="text" name="username"><br> 邮箱: <input type="text" name="usermail"><br> </fieldset> <button type="button" onclick="form.personalia.style.backgroundColor='yellow'">改变控件的背景颜色</button> <input type="submit"> </form> <p><b>注意:</b>除了 Internet Explorer,其他主流浏览器都支持 name 属性。</p> </body> </html>
运行结果
Copyright © 2013 - 2019 Ancii.com All Rights Reserved
京ICP备18063983号-5
京公网安备11010802014868号