Home  >  Article  >  Web Front-end  >  html 整个表格上下左右居中,只能实现左右,我是想做一个登陆界面,不需要和数据库相连,新手求帮忙,_html/css_WEB-ITnose

html 整个表格上下左右居中,只能实现左右,我是想做一个登陆界面,不需要和数据库相连,新手求帮忙,_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:53:171310browse

table align="center"valign="middle" >


姓名



性别



年龄



密码



确认密码






回复讨论(解决方案)

<table align="center" valign="middle" style="height:180px;margin-top:-90px;top:50%;position: absolute;left:50%;margin-left:-120px;width:240px;"><tr><td>姓名</td><td><input type="text" name="name"></td></tr><tr><td>性别</td><td><input type="text" name="sex"></td></tr><tr><td>年龄</td><td><input type="text" name="age"></td></tr><tr><td>密码</td><td><input type="password" name="password"></td></tr><tr><td>确认密码</td><td><input type="password" name="password1"></td></tr><tr><td colspan="2"><input type="submit" value="注册"></td></tr></table>

谢谢大神,不过

是什么意思啊

谢谢大神,不过

是什么意思啊
居中的样式

好简洁,不过效果怎么确认密码那“码”上了第二行呢
姓名
性别
年龄
密码
确认密

好简洁,不过效果怎么确认密码那“码”上了第二行呢
姓名
性别
年龄
密码
确认密


调整下宽度margin-left为(-width/2)

改了,还是那样图片传不上来,大神你能加我qq吗?我再传给你,2650117496

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn