[英]HTML, CSS issue: HTML fieldset placing/positioning
I have a HTML page with personal information details using text boxes. 我有一个HTML页,其中包含使用文本框显示的个人信息详细信息。 I have two fieldsets as in
我有两个字段集
As noticed that the fieldsets are placed up and down position. 如前所述,字段集处于上下位置。 My question is that
我的问题是
How can I placed these two fieldsets side by side (left & right position)? 如何将这两个字段集并排放置(左右位置)?
Thank you 谢谢
Remove width:40%
from form
& give float
to your fieldsets
. 从
form
删除width:40%
,并为您的fieldsets
float
。
Check this: http://jsfiddle.net/XdRYT/8/ 检查此: http : //jsfiddle.net/XdRYT/8/
Simplest solution is create table with two cells and one row and place each fieldset in different cell. 最简单的解决方案是创建具有两个单元格和一行的表,并将每个字段集放在不同的单元格中。 Another bit more complicated is to use CSS to format it.
更为复杂的一点是使用CSS对其进行格式化。
Change fieldset stye to below 将fieldset stye更改为以下
fieldset {
border: 1px dotted #61B5CF;
margin-top: 1.4em;
padding: 0.6em;
float:left;
width:40%;
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.