Quartermain
19-06-2008, 02:30
Lỗi fix ảnh png để hiện thị lên IE 6 trong suốt thì ok rồi. Nhưng đó là trong trường hợp là 1 bức ảnh muốn đưa lên.Nhưng ở đây mình lại muốn bức ảnh PNG đó là 1 background. thì nói lại ko được.
Khi chèn đoạn code này:
position:relative;
behavior: expression((this.runtimeStyle.behavior="none")&&(this.pngSet?this.pngSet=true:(this.nodeName == "IMG" && this.src.toLowerCase().indexOf('.png')>-1?(this.runtimeStyle.backgroundImage = "none",
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader (src='" + this.src + "', sizingMethod='image')",
this.src = "transparent.gif"):(this.origBg = this.origBg? this.origBg :this.currentStyle.backgroundImage.toString().repl ace('url("','').replace('")',''),
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader (src='" + this.origBg + "', sizingMethod='crop')",
this.runtimeStyle.backgroundImage = "none")),this.pngSet=true)
);
vào trong class mà chứa background đó thì ok. Nhưng lại có 1 việc xẩy ra là mọi thẻ khi viết HTML lên background đó hầu như ko có tác dụng
ví dụ: thẻ a, input, ...
bác bro nào biết xin chỉ giáo với
Khi chèn đoạn code này:
position:relative;
behavior: expression((this.runtimeStyle.behavior="none")&&(this.pngSet?this.pngSet=true:(this.nodeName == "IMG" && this.src.toLowerCase().indexOf('.png')>-1?(this.runtimeStyle.backgroundImage = "none",
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader (src='" + this.src + "', sizingMethod='image')",
this.src = "transparent.gif"):(this.origBg = this.origBg? this.origBg :this.currentStyle.backgroundImage.toString().repl ace('url("','').replace('")',''),
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader (src='" + this.origBg + "', sizingMethod='crop')",
this.runtimeStyle.backgroundImage = "none")),this.pngSet=true)
);
vào trong class mà chứa background đó thì ok. Nhưng lại có 1 việc xẩy ra là mọi thẻ khi viết HTML lên background đó hầu như ko có tác dụng
ví dụ: thẻ a, input, ...
bác bro nào biết xin chỉ giáo với