小白教程
所有教程
关于
Search
172.69.59.107
172.69.59.107
参数设置
贡献
退出
操作
编辑
移动
保护
信息
历史
删除
查看“Css3 pr box direction”的源代码
本页内容
上一节:
Css3_pr_box_align
下一节:
Css3_pr_box_flex
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
{{DISPLAYTITLE:box-direction}}[[Category:css reference|114]] = CSS3 box-direction 属性 = 由右至左,显示一个div box的子元素: <sample title="" desc="" lang="html" hererun="1"> div { width:350px; height:100px; border:1px solid black; /* Internet Explorer 10 */ display:-ms-flexbox; -ms-flex-direction:row-reverse; /* Firefox */ display:-moz-box; -moz-box-direction:reverse; /* Safari, Opera, and Chrome */ display:-webkit-box; -webkit-box-direction:reverse; /* W3C */ display:box; box-direction:reverse; } </sample> <run name=""> <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>小白教程(xiaobai.wang)</title> <style> div { width:350px; height:100px; border:1px solid black; /* Internet Explorer 10 */ display:-ms-flexbox; -ms-flex-direction:reverse; /* Firefox */ display:-moz-box; -moz-box-direction:reverse; /* Safari, Opera, and Chrome */ display:-webkit-box; -webkit-box-direction:reverse; /* W3C */ display:box; box-direction:reverse; } </style> </head> <body> <div> <p>Cat</p> <p>Dog</p> <p>Horse</p> </div> <p><b>注意:</b> Flexible boxes 在 IE 9和更早版本的浏览器中不兼容</p> </body> </html> </run> == 浏览器支持 == 目前主流浏览器不支持 box-direction 属性。 Internet Explorer 10通过私有属性 the -ms-flex-direction 支持. Firefox通过私有属性- MOZ-box-direction支持。 Safari和Chrome通过私有属性-WebKit-box-direction属性。 '''注意:''' Internet Explorer 9及更早IE版本不支持弹性框. == 属性定义及使用说明 == box-direction属性指定显示哪个方向的box的子元素。 {| class="table table-striped table-hover" | 默认值: | normal |- | 继承性: | no |- | 版本: | CSS3 |- | JavaScript 语法: | object.style.boxDirection="reverse" |} == 语法 == box-direction: normal|reverse|inherit; {| class="table table-striped table-hover" ! 值 ! 描述 |- | normal | 以默认方向显示子元素。 |- | reverse | 以反方向显示子元素。 |- | inherit | 应该从子元素继承 box-direction 属性的值 |}
返回至“
Css3 pr box direction
”。
上一节:
Css3_pr_box_align
下一节:
Css3_pr_box_flex