css表單示範

來源:互聯網
上載者:User

<html><head><title>表單</title><style><!--form {border: 1px dotted #AAAAAA;padding: 3px 6px 3px 6px;margin:0px;font:14px Arial;}input {color: #00008B;background-color: #ADD8E6;border: 1px solid #00008B;}select {width: 80px;color: #00008B;background-color: #ADD8E6;border: 1px solid #00008B;}textarea {width: 200px;height: 40px;color: #00008B;background-color: #ADD8E6;border: 1px solid #00008B;}--></style>   </head><body><form method="post"><p>請輸入您的姓名:<br><input type="text" name="name" id="name"></p><p>請選擇你最喜歡的顏色:<br><select name="color" id="color"><option value="red">紅</option><option value="green">綠</option><option value="blue">藍</option><option value="yellow">黃</option><option value="cyan">青</option><option value="purple">紫</option></select></p><p>請問你的性別:<br><input type="radio" name="sex" id="male" value="male">男<br><input type="radio" name="sex" id="female" value="female">女</p><p>你喜歡做些什麼:<br><input type="checkbox" name="hobby" id="book" value="book">看書<input type="checkbox" name="hobby" id="net" value="net">上網<input type="checkbox" name="hobby" id="sleep" value="sleep">睡覺</p><p>我要留言:<br><textarea name="comments" id="comments" cols="30" rows="4"></textarea></p><p><input type="submit" name="btnSubmit" id="btnSubmit" value="Submit"></p></form></body></html>
相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.