实例
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>用户注册</title> </head> <body> <p>菜单栏</p> <ul> <li>首页</li> <li>关于我们</li> <li>新闻中心</li> <li>产品中心</li> <li>联系我们</li> </ul> <h3>新闻列表</h3> <ol> <li>今天是我的第1次作业。</li> <li>这是一个HTML页面。</li> <li>每一天必须要完成作业。</li> <li>如果不坚持,你会后悔这一年。</li> <li>请加油吧,坚持写代码。</li> </ol> <ul> <li><a href="">首页</a></li> <li><a href="">关于我们</a></li> <li><a href="">新闻中心</a></li> </ul> <h3>表格开始</h3> <table border="1" cellpadding="5" cellspacing="0"> <caption>学员信息表</caption> <thead> <tr bgcolor="#6495ed"> <td>ID</td> <td>姓名</td> <td>姓别</td> <td>专业</td> <td>学校</td> </tr> </thead> <tbody> <tr> <td width="40px">1</td> <td width="80px">小红</td> <td width="40px">女</td> <td width="90px">计算机</td> <td width="90px">小学校</td> </tr> <tr> <td>2</td> <td>小白</td> <td>男</td> <td>数学</td> <td rowspan="2">小黑赤</td> </tr> <tr> <td>3</td> <td>小黑</td> <td>女</td> <td>画画</td> </tr> <tr> <td>4</td> <td>小化</td> <td>女</td> <td>篮球</td> <td>云里</td> </tr> </tbody> <tfoot> <td>共计</td> <td colspan="4">4人</td> </tfoot> </table> <h3>用户注册</h3> <form action=""> <p> <label for="username">帐号:</label> <input type="text" id="username" name="username" placeholder="不超过8个汉字"> </p> <p> <label for="password">密码:</label> <input type="password" id="password" name="password" placeholder="复杂一些的密码"> </p> <p> <label for="email">Email:</label> <input type="email" id="email" name="email" placeholder="abc@qq.com" required> </p> <p> <label for="age">年龄:</label> <input type="number" id="age" name="age" placeholder="输入岁数"> </p> <p> <label for="birthday">生日:</label> <input type="date" id="birthday" name="birthday" placeholder="你的生日"> </p> <p> <label>课程:</label> <select name="kecheng" id="kecheng"> <optgroup label="前端"> <option value="1">HTML</option> <option value="2">CSS</option> <option value="3">javascript</option> </optgroup> <optgroup label="后端"> <option value="4">PHP</option> <option value="5">JAVA</option> <option value="6">NET</option> <option value="7">NODEJS</option> </optgroup> </select> </p> <p> <label>爱好:</label> <input type="checkbox" name="love[]" value="book" id="book"> <label for="book">看书</label> <input type="checkbox" name="love[]" value="sleep" id="sleep"> <label for="sleep">睡觉</label> <input type="checkbox" name="love[]" value="happy" id="happy"> <label for="happy">开心</label> </p> <p> <label>姓别:</label> <input type="radio" name="xingbie" id="man" value="man"> <label for="man">***</label> <input type="radio" name="xingbie" id="woman" value="woman"> <label for="woman">***</label> </p> <p> <label for="content">备注:</label> <textarea name="content" id="content" maxlength="500" cols="50" rows="10"></textarea> </p> <p> <input type="submit" value="提交" name="submit"> <input type="reset" value="重置" name="reset"> <input type="button" value="确定"> </p> </form> </body> </html>
运行实例 »
点击 "运行实例" 按钮查看在线实例