Zen Cart Logo
If this is your first visit, check our documentation. To post, register or login.
Forums / Customizing the Look of Your Shop / Templates, Stylesheets, Page Layout / Images with width percentages messing up on IE when image res is high

Images with width percentages messing up on IE when image res is high

Locked

Started by donn on 8 Apr 2010, 4:30 PM · Views: 1,303

Results 1 to 3 of 3
This thread is locked. New replies are disabled.
8 Apr 2010, 4:30 PM
#1
donn avatar

donn

Zen Follower

Join Date:
Oct 2007
Posts:
241
Plugin Contributions:
0

Post #1 by donn

Hello, ppl. :smile:

The following code is of issue:

<table border="0" cellpadding="0" cellspacing="12" width="100%"> <tr> <td width="14%"> <img img border="0" src="http://www.internet.org/image1.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image2.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image3.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image4.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image5.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image6.gif" width="98%" </td> <td width="14%"> <img img border="0" src="http://www.internet.org/image7.gif" width="98%" </td>
      </tr>
    </table>

On Firefox, no matter HOW wide the images are, the page appears perfectly. The images are sized to fit the page at 100%. There is no horizontal scrolling of the page.

BUT--the same images --on new and old IE versions -- appear VERY differently: The images appear WAY larger than they should.

Now, the issue is this: If I shrink down the images (my quick fix) then when the above code displays in IE, it fits. (I resized the images to fit in even a smaller screen size, so they are a tiny bit smaller...that was the idea of using percentages, after all!)

BUT---with my quick fix, when the images are rendered on a larger screen, they are being increased slightly beyond their original pixel width, and it looks lousy.

For now, this is what I've done.

But I am wondering if there's a way to accomplish this using DIVs, or something else. In other words, how do I keep the table from stretching to accommodate the images at full size, as IE seems to be doing?

8 Apr 2010, 4:38 PM
#2
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Post #2 by schoolboy

<td width="14%"> <img img border="0" src="http://www.internet.org/image1.gif" width="98%" </td>

I don't see a closing tag bracket ... >

<td width="14%"> <img img border="0" src="http://www.internet.org/image1.gif" width="98%"**>** </td>

20 years a Zencart User

8 Apr 2010, 4:53 PM
#3
donn avatar

donn

Zen Follower

Join Date:
Oct 2007
Posts:
241
Plugin Contributions:
0

Post #3 by donn

schoolboy:

<td width="14%"> <img img border="0" src="http://www.internet.org/image1.gif" width="98%" </td>

I don't see a closing tag bracket ... >

<td width="14%"> <img img border="0" src="http://www.internet.org/image1.gif" width="98%"**>** </td>

Sorry; there was one! I had to remove the actual URL, subdir, and image names, and I seem to have done so sloppily!