:在IE浏览器中不起作用之后



标题前的箭头使用:before显示。此问题只在ie浏览器上出现。

//编辑:这里有错误,我的样式在p上。也许这就是问题所在?

代码如下:

.special-title {
  font-size: 24px;
  color: #a4a19e;
  line-height: 1.2;
  position: relative;
  padding: 8px 0 8px 38px;
  border-top: 1px solid #e2dbcf;
  border-bottom: 1px solid #e2dbcf;
  margin-top: 49px;
  margin-bottom: 25px; }
.special-title:before {
  content: url('../img/general-title-decoration.svg?1369571463');
  position: absolute;
  width: 28px;
  left: 0;
  top: 23px;
  margin-top: -13px; }

按钮:

.btn-call-to-action a {
  background: #8e8287;
  color: #f5f3e2;
  padding: 2px 60px 2px 10px;
  height: 35px;
  line-height: 40px;
  margin-top: 6px;
  display: inline-block;
  position: relative;
  border-radius: 2px;
  height: 40px;
  white-space: nowrap;
  -webkit-transition: all 0.2s ease-in-out;
  -moz-transition: all 0.2s ease-in-out;
  -o-transition: all 0.2s ease-in-out;
  -ms-transition: all 0.2s ease-in-out;
  transition: all 0.2s ease-in-out; }
.btn-call-to-action a:hover:after {
  -webkit-transform: translatex(6px);
  -moz-transform: translatex(6px);
  -o-transform: translatex(6px);
  -ms-transform: translatex(6px);
  transform: translatex(6px); }
.btn-call-to-action a:hover {
  background: #6f6469;
  border-bottom: none; }
.btn-call-to-action a:after {
  content: url('../img/general-white-arrow.svg?1369574895');
  position: absolute;
  width: 35px;
  right: 15px;
  top: 0px;
  -webkit-transition: all 0.2s ease-in-out;
  -moz-transition: all 0.2s ease-in-out;
  -o-transition: all 0.2s ease-in-out;
  -ms-transition: all 0.2s ease-in-out;
  transition: all 0.2s ease-in-out; }

这里是活动站点:http://aurelieremia.be/tfa/

在.special-title:之前,由于您使用的是绝对定位,因此请删除

margin-top:-13px; 

,直接用

top:10px; 

。然后,声明高度和宽度。

见http://jsfiddle.net/6TdB6/

最新更新