gpt4 book ai didi

html - -webkit-填充-开始 : 40px; What it should be for IE and Firefox?

转载 作者:技术小花猫 更新时间:2023-10-29 12:04:48 25 4
gpt4 key购买 nike

-webkit-padding-start: 40px; 适用于 Chrome

IEFirefox 有什么用?

最佳答案

对于 Firefox,属性名称是 -moz-padding-start .对于 IE,没有对应的(到目前为止)。

至少在页面整体为从左到右或从右到左的布局和书写方向的简单场景中,您可以使用广泛支持的 CSS 功能实现相同的效果。使用 <html dir=ltr><html dir=rtl> ,分别,你可以这样写你的 CSS 代码:

[dir=ltr] .foo {
padding-left: 2.5em;
}
[dir=rtl] .foo {
padding-right: 2.5em;
}

这对应于 .foo { padding-start: 2.5em; } .当然,这种方法意味着一些代码重复。但它几乎可以 100% 工作(包括 IE 7 和标准模式下的更新版本)。

关于html - -webkit-填充-开始 : 40px; What it should be for IE and Firefox?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12549591/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com