【问题标题】:why internet explorer phone enlarges elements?为什么网络浏览器手机放大元素?
【发布时间】:2015-07-23 14:01:41
【问题描述】:

我正在对网站进行响应,例如在 chrome 上一切都按预期工作。我使用设备模式来模拟网站的响应版本。但是,当我使用 Internet Explorer 时,一切都会变得更大,并且图片会像拉伸它们时一样出现像素化。

我尝试使用双三次 css 属性,但没有骰子。此外,缩放选项为 100%(听说其他人已将其放大)。

这就是罪魁祸首项目的代码的样子

HTML

<div id="category-contents">
    <div class="cell-wrapper">
        <div class="cell-wrapper-inside">
            <a href="http://www.theperfecturn.com/small-cross-cremation-jewelry-c-481.html" class="image product-thumb-image" style="background: url('images/categories/sm/481.smallcrosscremat_sm.jpg') 2px 2px no-repeat;"><img src="http://cdn.perfectmemorials.com/categories_layout/photo-frame.png" alt="Small Cross Cremation Jewelry" title=" Small Cross Cremation Jewelry " width="124" height="124"> </a>

            <a href="http://www.theperfecturn.com/small-cross-cremation-jewelry-c-481.html" class="title">Small Cross Cremation Jewelry</a>

            <div class="button-wrapper"><a href="http://www.theperfecturn.com/small-cross-cremation-jewelry-c-481.html"><img src="http://cdn.perfectmemorials.com/categories_layout/button-category.gif" class="category" alt="View Small Cross Cremation Jewelry Category"></a></div>
        </div>
    </div>
</div>

CSS

#category-contents{
    overflow: hidden;
}    

#category-contents .cell-wrapper,
#results-products .cell-wrapper{
    box-sizing: border-box;

    width: 50%;
    height: auto;
}

#category-contents .cell-wrapper .title{    
    height: 65px;
}

#results-products .cell-wrapper .title{

}

#category-contents .cell-wrapper .cell-wrapper-inside,
#results-products .cell-wrapper .cell-wrapper-inside{
    height: auto;
    width: auto;
}

#category-contents .cell-wrapper .button-wrapper,
#results-products .cell-wrapper .button-wrapper{
    position: static;
    width: auto;
}

.cell-wrapper .button-wrapper .product{
    float: none !important;

}

.cell-wrapper .button-wrapper .volume{
    float: none !important;
    margin-bottom: -5px;
}

http://puu.sh/hKEHh/3ceb0a9168.jpg http://puu.sh/hKEP6/3f8f2aad40.jpg

【问题讨论】:

    标签: html css internet-explorer mobile responsive-design


    【解决方案1】:

    我的建议是将正文的填充和边距归零

    所以添加到你的css

    body {
    padding: 0;
    margin: 0;
    }
    

    如果不访问实际文件,很难确切地看到正在发生的事情

    【讨论】:

      猜你喜欢
      • 2011-05-24
      • 2014-05-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-04-09
      • 1970-01-01
      • 2020-03-13
      • 2015-03-14
      相关资源
      最近更新 更多