前端学习(179):表单元素

时光总嘲笑我的痴心妄想 提交于 2019-12-23 06:58:58
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/ html4/strict.dtd">
<html>
    <head>
        <meta http-equiv="content-type" content="text/html; charset=utf-8">
        <title>表单</title>
    </head>
    <body>
        <h1>注册账号</h1>
        <form action="regist" method="post">
            用户名:<input type="text" name="username" id="username" value="" />
            <input type="button" name="checkusername" id="checkusername" value="检查用户名是否被注册" /><br />
            密码:<input type="password" name="password" id="password" value="" /> <br />
            确认密码:<input type="password" name="" id="re_password" value="" /> <br />
            性别:<input type="radio" name="sex" id="sex_man" value="man" checked="checked" />男 <input type="radio" name="sex" id="sex_woman"
             value="woman" />女<br />
            兴趣爱好:<input type="checkbox" name="interest" id="ins_football" value="football" />足球 <input type="checkbox" name="interest"
             id="ins_volleyball" value="volleyball" />排球 <input type="checkbox" name="interest" id="ins_ping-pong" value="ping-pong" />乒乓球<br />
            选择头像:<input type="file" name="file" id="file" value="" /><br />
            <input type="image" width="80" height="80" src="pic/submit.jpg" alt="我是歌谣"/> <br />
            <input type="reset" value="重置信息" /> <input type="submit" id="submit" value="注册账号" />
            <input type="hidden" name="regist" id="" value="default" />
        </form>
    </body>
</html>

运行结果

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!