相关疑难解决方法(0)

任何人都知道为什么这样:在CSS不能在IE9中工作?

此提交按钮应在左侧舍入,并指向右侧.它在非ie浏览器中工作,但在IE9中,它不起作用.

如果我查看开发人员工具中的样式,.flat-button:在规则之后将所有内容划掉,就像它被某些东西取代一样.什么?

<button type="submit" class="flat-button">Submit</button>
<style>
.flat-button {
    float: left;
    position: relative;
    border-top-left-radius: 5px;
    -moz-border-top-left-radius: 5px;
    -webkit-border-top-left-radius: 5px;
    border-bottom-left-radius: 5px;
    -moz-border-bottom-left-radius: 5px;
    -webkit-border-bottom-left-radius: 5px;
    border: none;
    padding: 0 12px;
    margin: 0 3px 3px 0;
    outline: none;
    cursor: pointer;
    color: white;
    font-family:'Trebuchet MS', Arial, helvetica, Sans-Serif;
    font-size: 14px;
    font-weight: bold;
    font-style: italic;
    text-decoration: none;
    border-collapse: separate;
    height: 26px;
    line-height: 26px;
    background: #5191cd;
}
.flat-button:hover {
    background: #1c3f95;
}
.flat-button:after {
    position: absolute;
    content: ' ';
    height: 0;
    width: 0;
    left: …
Run Code Online (Sandbox Code Playgroud)

css pseudo-element internet-explorer-9

7
推荐指数
1
解决办法
8282
查看次数

Div内部按钮在IE中无法正常工作

我想在一个绝对<div>元素中定位<button>,元素需要稍微超出按钮边界,如下所示:

HTML:

<button class="container">
  <div class="child">child</div>
</button>
Run Code Online (Sandbox Code Playgroud)

CSS:

.container {
  position: relative;
}
.child {
  position: absolute;
  top: -1rem;
  left: 1rem;
}
Run Code Online (Sandbox Code Playgroud)

这与我在Chrome中的预期完全一样,但是在IE中,孩子没有离开按钮边界,这是小提琴.

铬:

铬

IE

IE

在IE 11和Chrome 51中测试过.

html css internet-explorer google-chrome

1
推荐指数
1
解决办法
1187
查看次数