|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi
I am displaying a series of images with text aligned to the right of these images. Each line basically contains an image, then some text, some space and then the same again, an image and some text. Then it goes down to the next line where it happens again. The problem resides in the fact in IE there correctly is a 1em gap between the image and the image above. However in Netscape 6 the image below is flush to the image above. This problem can be solved by increasing the margin/padding value but this then increases the margin/padding in IE and makes it too much!! Is there something I should be coding to increase the margin in Netscape that wont increase in IE? Here is my HTML:- <div id="content"> <div class="medpics"> <a href="#"><img src="../eg_med.gif" width="40" height="50" border="0" alt="" /></a><a href="#" title="#"> </a>Lorem ipsum dolor sit ame<br /> Lorem ipsum dolor si</div> <div class="medpics"> <a href="#"><img src="../eg_med.gif" width="40" height="50" border="0" alt="" /></a><a href="#" title="#"> </a>Lorem ipsum dolor sit ame<br /> Lorem ipsum dolor si</div> <div class="medpics"> <a href="#"><img src="../eg_med.gif" width="40" height="50" border="0" alt="" /></a><a href="#" title="#"> </a>Lorem ipsum dolor sit ame<br /> Lorem ipsum dolor si</div> </div> and the CSS :- #content { margin: 0 22% 0 0; padding-left: 1.5%; font-size: 0.8em; } .medpics img { float: left; margin-right: 0.5em; border: 0.1em outset #ffffff; } .medpics { float: left; margin-bottom: 1em; width: 350px; } And ideas would be greatly appreciated!! Last edited by Mr X : August 5th, 2003 at 09:50 AM. |
|
#2
|
|||
|
|||
|
Has nobody got any ideas?
|
|
#3
|
||||
|
||||
|
Try using a percentage for your margin instead of em.
__________________
# Jeremy Explain your problem instead of asking how to do what you decided was the solution. |
|
#4
|
||||
|
||||
|
think its a bug in netscape 6,
i've tried your code in mozilla 1.2 / 1.5a and mozFb and can not reproduce your problem, so even there is ways avoid ie to read css, it would afffect later version of gecko based browsers too, Last edited by Akh : August 6th, 2003 at 04:58 AM. |
|
#5
|
|||
|
|||
|
I have changed the margin to % now, it does indeed seem to work much better now in netscape 6, and still remains the same in ie which is good. Opera does render the gap slightly bigger now, but I can live with that!
Thanks everyone! It is much appreciated. |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > Netscape 6 css margin/padding problem! |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|