【问题标题】:why is the a tag lower then the spans in IE为什么a标签比IE中的span低
【发布时间】:2011-11-01 10:27:39
【问题描述】:

这是我的page

HTML

<div class="pp-foot">
  <span class="big-call-btn"></span>
  <span class="big-chat-btn"></span>
  <a href="#contact_form_photo" rel="prettyPhoto[inline]" class="footer_btn_email_new  big-email-btn"><span></span></a>
</div>

CSS

.pp-foot {
    background: url("../images/prod-page-foot.jpg") no-repeat scroll center top #E4E4E4;
    height: 77px;
}

.big-chat-btn {
   background: url("../images/product-chat-btn.png") no-repeat scroll center top transparent;
   margin: 0 0 0 11px;
}

.pp-foot a {
    margin: 0 0 0 11px;
}
.big-email-btn {
    background: url("../images/product-email-btn.png") no-repeat scroll center top transparent;
}
.big-call-btn, .big-chat-btn, .big-email-btn {
    display: inline-block;
    height: 72px;
    width: 230px;
}

任何导致问题的想法。 Firefox 很好,但 IE 不行

【问题讨论】:

  • 不明白。在 FF 和 IE 中看起来相同。问题出在页面的哪个位置?

标签: html css


【解决方案1】:

您需要添加vertical-align: top

.big-call-btn, .big-chat-btn, .big-email-btn {
    display: inline-block;
    vertical-align: top;
    height: 72px;
    width: 230px;
}

更多信息:

【讨论】:

猜你喜欢
  • 2012-11-03
  • 1970-01-01
  • 2010-11-24
  • 1970-01-01
  • 2017-01-18
  • 1970-01-01
  • 2012-02-17
  • 1970-01-01
  • 2012-03-18
相关资源
最近更新 更多