Hi, I've added some script to randomly display one of 3 images on my homepage, but I've set it to display in the background of a table so that if the window is resized it just shows more or less of the image.
For some reason it only displays correctly in Safari on Mac. I've tested on Firefox, Opera, Netscape & Explorer on PC and Mac and none of these display correctly. The code for the table (in /customer/main/welcome.tpl) is:
Code:
<table width="100%" height="290" border="0" cellspacing="0" cellpadding="0" background="{$ImagesDir}/homepics/psco{"1"|mt_rand:3}.jpg" class ="HomepagePics">
<tr>
<td></td>
</tr>
</table>
And the CSS style I've attached to the table is:
Code:
.HomepagePics {
background: #fff no-repeat;
}
Can anyone see why it won't display in most browsers??
If I have the image display directly in the table it works in all browsers but it stretches the screen to the size of the image which I don't want. That code is:
Code:
<table width="100%" height="290" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>[img]{$ImagesDir}/homepics/psco{[/img]</td>
</tr>
</table>
Thanks for any help!! - I have asked this one before but had no replies
