Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/video/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 在Internet Explorer 8的DIV中安装图像_Html_Css_Internet Explorer - Fatal编程技术网

Html 在Internet Explorer 8的DIV中安装图像

Html 在Internet Explorer 8的DIV中安装图像,html,css,internet-explorer,Html,Css,Internet Explorer,我需要显示一个适合div标签的图像。这段代码在Chrome上运行得很好,但当我在InternetExplorer8上可视化它时,我会得到一个裁剪过的图像。这是我的密码 .grid{ background:url('./images/grid.png'); background-repeat:no-repeat; width:730px; height:647px; background-size: contain; background-size:

我需要显示一个适合div标签的图像。这段代码在Chrome上运行得很好,但当我在InternetExplorer8上可视化它时,我会得到一个裁剪过的图像。这是我的密码

.grid{ background:url('./images/grid.png'); background-repeat:no-repeat; width:730px; height:647px; background-size: contain; background-size: 100% 100%; } .电网{ 背景:url('./images/grid.png'); 背景重复:无重复; 宽度:730px; 高度:647px; 背景尺寸:包含; 背景大小:100%100%; }

...
不知道是否有用,但我得用

<!DOCTYPE html public "-//W3C//DTD HTML 4.0 Transitional//en">


您应该知道
背景大小
不受IE8的支持

您应该知道
背景大小
不受IE8的支持

属性
背景大小
在IE8中不起作用

您应该尝试在div中添加一个
标记,并使用
最大宽度:100%


属性
背景大小
在IE8中不起作用

您应该尝试在div中添加一个
标记,并使用
最大宽度:100%


图像有多大?也许JS提琴会有帮助?图像有多大?也许JS提琴会有帮助?为什么您需要
最大高度
?高度应根据
最大宽度:100%自行调整。如果由于某种原因高度无法调整,请使用
height:auto
有时图像的高度较大,但宽度较小,因此可能不适合宽度,在这种情况下,使用
max height
是有意义的…为什么需要
max height
?高度应根据
最大宽度:100%自行调整。如果由于某种原因高度无法调整,请使用
height:auto
有时图像的高度较大,但宽度较小,因此可能不适合宽度,在这种情况下,使用
max height
是有意义的。。。
<!DOCTYPE html public "-//W3C//DTD HTML 4.0 Transitional//en">