Jump to content

Archived

This topic is now archived and is closed to further replies.

eclipse

IE (all) image size issue.

Recommended Posts

eclipse

Hello everyone! I'm using DMS v1.0.2 and there seems to be a problem with images in Internet Explorer. Images are shown in their actual size, ignoring "width" and "height" attribute of the HTML <img> tag. This problem seems to be caused by CSS hack for IE, found in the "pl-structure.less" file, string 247: width: auto\9; /* ie8 */.

 

Is there any way to fix/override this?

Share this post


Link to post
Share on other sites
Danny

Hi,

 

I don't have access to IE and don't trust BrowserStack to give an accurate representation. Therefore, would it be possible for you to provide a few screenshots please.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
eclipse

Here is how it looks in FF:

 

[sharedmedia=core:attachments:1453]

 

And here is how the same page looks in IE 10:

 

[sharedmedia=core:attachments:1454]

 

Original image size is 1404x1755. The <img> tag contains attributes width="242" and height="303", which are seems to be ignored by IE. In other browsers everything is fine. This applies to any image on the website. Removing string 247: width: auto\9; /* ie8 */ in the "pl-structure.less" file helped while using previous DMS version 1.0.1. I've just updated to 1.0.2 and commenting this line out doesn't solve this issue any more. I don't think that hacking themes core is a good sulution anyway.

Share this post


Link to post
Share on other sites
Rob

Hi,

 

IE does not handle image scaling at all well, if at all.  Rather, it will render a scaled image as full size, that appears fine, scaled, in other browsers.  The solution as I've written in the Framework forums many times, is to resize your image in a graphics editor and simply replace the large image with one that is the size you expect it to appear across all browsers.  If you're hoping to have the image open up a larger screen, you'd need to use a plugin for that, but still the normally displayed image on the page or post should always be the actual display size, not a scaled down size.

 

This applies to thumbnails, post images, feature slides, etc. Any image, essentially.


Former PageLines Moderator, Food Expert and Raconteur

Share this post


Link to post
Share on other sites
eclipse

One Smart Egg, thanks for your answer. It's sad that this issue have no proper solution. I can't understand the reason the IE CSS hack (width: auto\9;) was used for, and cannot remove this string either - since I don't want this code to be overwritten during next update. But thank you anyway.

Share this post


Link to post
Share on other sites
Jackey

Think this is related to: http://forum.pagelines.com/topic/29459-image-sizing-in-firefox/?p=172852

And prob. will be fixed simultaneously.

 

Has to do with:

width: auto;

 

vs

 

width: 100%;

 

that FF and IE prefer.

 

Quick dirty Fix:*

body.firefox .pl-content img, body.ie .pl-content img {

    width: 100%;
}
 
*You need to have "Browser Specific CSS" plugin activated for this.

Share this post


Link to post
Share on other sites

×