ie6图像拉伸和缩放

发布于 2024-09-28 22:15:45 字数 448 浏览 2 评论 0原文

我需要能够拉伸图像背景以适应窗口大小,现在它适用于除 ie6 之外的所有浏览器 我在互联网上无休止地搜索解决方案,并尝试了我找到的所有方法,但在 ie6 中似乎没有任何效果,

这是我的演示网站,如果你有 ie6,你将能够看到我的问题 我也需要它拉伸整个宽度和高度,而不扭曲图像

http://demo.jigsawfinance.com /

任何人都知道一种可行的解决方案我有 img 标签等,但对于那些没有 ie6 的人来说仍然无济于事,

这里是屏幕 veiw

alt text

正如你所看到的,我有很多空白区域,图像也应该扩展

I need to be able to stretch a image background to fit the window size now it works in all browsers except for ie6
I have endlesly searched the internet for a solution and tried all things I have found but nothing seems to work in ie6

here is my demo site if you have ie6 you will be able to see my problem
I need it too stretch the full width and height with out it distorting the image at all

http://demo.jigsawfinance.com/

any one know a solution that will work I have the img tag etc but still no avail

for those without ie6 here is a capture of the screen veiw

alt text

as you can see I have alot of white space where the image is supposed to expand too

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

北座城市 2024-10-05 22:15:45

CSS 3 有一种方法可以做到这一点,但由于 IE6 不支持它,我认为最好的选择是使用 img 标签。

例如,

<img src="../images/jigsaw_logo.png" style="width: 100%; position: absolute; top: 0; left: 0; z-index: -1;"/>

这将保留图像的比例并将其移回原处。

另请注意,在 IE 的 css 中,您可以指定表达式,因此如果您在正常 100% css 宽度方面遇到问题,请尝试下面的一种:

width: expression(document.body.clientWidth + 'px');

There is a way for CSS 3 to do this but since IE6 does not support it, I think your best bet is to use the img tag.

e.g.

<img src="../images/jigsaw_logo.png" style="width: 100%; position: absolute; top: 0; left: 0; z-index: -1;"/>

This will retain the proportion of your image and move it back.

Also take note that in IE's css, you can specify expressions, so try the one below if you're having trouble with the normal 100% css width:

width: expression(document.body.clientWidth + 'px');
哎呦我呸! 2024-10-05 22:15:45

IE6 的图像拉伸没有质量损失:

<div Style="Position:Relative; Width:2000px; Height:1500px;
Filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(
Src='C:\SomePic.jpg',SizingMethod='scale');"></div>

Image stretching with no quality loss for IE6:

<div Style="Position:Relative; Width:2000px; Height:1500px;
Filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(
Src='C:\SomePic.jpg',SizingMethod='scale');"></div>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文