如何横向设置ul样式

时间:2015-08-30 12:00:11

标签: css

我正在尝试水平列出表单标签和按钮。

这是我的CSS代码:

.viewLayout ol{
width: 1px;
float:left;
}
.viewLayout ol > li{
direction:ltr;
display: inline;
}
.viewLayout input[type=button] {
display:block;
width: 100px;
color:#FFF;
background-color: #808285;
border: 0 none;
border-radius: 3px;
font-size: 1.1em;
font-weight: bold;
height:22px;
cursor: pointer;
font-size: 13px;
}

我的代码结果: enter image description here

如何设置编辑按钮的样式以与办公区域内联? 意思

1 个答案:

答案 0 :(得分:0)

width: 1px;说明中删除ol属性。显然,display:block来自input描述。

UPD:很有趣,但我的浏览器并没有将您的代码渲染为您的图片。确切地说,display:inline描述中的li会破坏标记。它应该删除。

相关问题