简体   繁体   English

如何css html在IE中显示图像,可以在Firefox,Chrome和Safari中查看?

[英]How to css html to display image in IE, which can be viewed in firefox, chrome, and safari?

These images on the bottom left of this link http://giantmango.com/i-love-art-13-3319 display in firefox, chrome, safari, but not in IE. 这些图片位于此链接的左下方http://giantmango.com/i-love-art-13-3319,它们以Firefox,chrome,safari显示,但不以IE显示。

How do I get them to show in IE? 如何使它们显示在IE中?

The HTML for your images currently looks like this: 图片的HTML当前如下所示:

<img src="....." alt="" title="I Love Art" width="200"   width="200" height=""/>

The problem is the empty height attribute (IE is treating this as though the height is set to 1 ). 问题是空的height属性(IE将其视为将height设置为1 )。 Remove the attribute entirely. 完全删除该属性。

You should also remove the duplicated width attribute, so the final HTML is similar to: 您还应该删除重复的width属性,因此最终的HTML类似于:

<img src="....." alt="" title="I Love Art" width="200" />

由于某些原因,在IE中, img元素的height属性设置为1

<img width="200" height="1" title="I Love Art" alt="" src="http://giantmango.com/wp-content/uploads/japanese-style.jpg" complete="complete"/>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在Safari,Chrome和IE中显示的图片div,但在Firefox中不显示 - Image div showing in Safari, Chrome and IE but not in Firefox CSS图像调整大小仅在Firefox和IE中混乱,在Safari和Chrome中正常工作 - css image resize messing up only in firefox and IE, works fine in safari and chrome HTML / CSS-Firefox与Chrome和IE之间的问题 - HTML/CSS - Issues between Firefox and Chrome, and IE html - css 检查铬,即 &amp; firefox - html - css check for chrome, ie & firefox 内联复选框可以在Chrome和Safari中正确显示,但不能在FireFox和IE中正确显示 - Inline Checkboxes Display Properly in Chrome & Safari but not FireFox & IE CSS子菜单定位可在Chrome和Safari中使用,但不适用于IE和Firefox - CSS Sub-menu positioning works in Chrome & Safari, but not IE and Firefox 内联CSS背景未在Chrome / Safari / IE上显示,但可在Mozilla Firefox上使用 - Inline css background not showing on Chrome/Safari/IE but it works on Mozilla Firefox CSS-Animation适用于Chrome和Safari,但不适用于Firefox和IE - CSS-Animation works in Chrome and Safari, but not Firefox and IE 如何使此CSS适应Chrome,IE,Safari? - How to adapt this CSS for Chrome, IE, Safari? HTML / CSS左右div并排在Chrome上,但在Safari / Firefox上不 - HTML/CSS left and right div side by side on Chrome but not on Safari/Firefox
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM