5 replies [Last post]
fritzer
Offline
newbie
Bartlesville, OK
Last seen: 15 years 50 weeks ago
Bartlesville, OK
Timezone: GMT+1
Joined: 2003-08-01
Posts: 3
Points: 0

I am working on this site:

http://www.valuenews.com
http://www.valuenews.com/css/vnbody.css

I have assigned negative top margins to several class styles to remove unwanted space between paragraphs/images and applied those styles to text and images within <div>s. The result looks fine in IE 5 Mac, Netscape Mac, Netscape 7 XP, but in IE 6 XP the reduced margins are lost.

Is this a known issue? What can I do?[/url][/b]

KnightWolfJK
KnightWolfJK's picture
Offline
Enthusiast
Washington, DC
Last seen: 12 years 4 weeks ago
Washington, DC
Timezone: GMT-5
Joined: 2003-06-10
Posts: 210
Points: 0

Text Margins not working in IE6

The page looks fine to me- I'm running WinXP Home/ IE6. I included a screenshot (shrunk, cropped, and compressed to meet filesize requirements) of what I'm seeing.

Diplomacy is the art of letting someone have your way

d3signmonk3y
d3signmonk3y's picture
Offline
Enthusiast
Toledo, Ohio
Last seen: 15 years 50 weeks ago
Toledo, Ohio
Timezone: GMT-4
Joined: 2003-07-29
Posts: 59
Points: 0

Text Margins not working in IE6

I'm not sure if I understand what you're describing correctly or not, but if regardless I don't think negative margins are the way to go. I seem to recall that some browsers don't go for that sort of thing.

If you want to affect the margins around paragraphs of text, adjust the margins dirrectly on the <p> tag. For instance:

p {
margin-top: 0;
margin-bottom: 1em;
}

will make paragraphs but right up against an item above them but keep one line of space between each other.

Again I'm not sure if I understand what your problem is, so I apologize if this is no help to you.

fritzer
Offline
newbie
Bartlesville, OK
Last seen: 15 years 50 weeks ago
Bartlesville, OK
Timezone: GMT+1
Joined: 2003-08-01
Posts: 3
Points: 0

Text Margins not working in IE6

Thank you both for your reponses.

Actually, the screen shot does confirm my problem. Specifically, I'm referring to the leading between the headlines, the body copy and the divider lines in the third column. Also the leading between the sub-header and body copy in the maroon boxes in the second column. I would much prefer to control and reduce that leading.

I didn't know you could use margin attributes directly within paragraph tags, so I will give that a try. But it seems like a step in the wrong direction at a time when I'm slowly working toward all-CSS formatting.

Any suggestions about how to accomplish the task with CSS?

Thanks again!

d3signmonk3y
d3signmonk3y's picture
Offline
Enthusiast
Toledo, Ohio
Last seen: 15 years 50 weeks ago
Toledo, Ohio
Timezone: GMT-4
Joined: 2003-07-29
Posts: 59
Points: 0

Text Margins not working in IE6

fritzer wrote:
I didn't know you could use margin attributes directly within paragraph tags, so I will give that a try. But it seems like a step in the wrong direction at a time when I'm slowly working toward all-CSS formatting.

:?: :?: :?: :?:

I'm not sure what you mean. In what way do you feel that controling the display of HTML tags with CSS goes against all-CSS formatting.

fritzer
Offline
newbie
Bartlesville, OK
Last seen: 15 years 50 weeks ago
Bartlesville, OK
Timezone: GMT+1
Joined: 2003-08-01
Posts: 3
Points: 0

Text Margins not working in IE6

I have realized that I was completely misunderstanding what you were saying. Despite my initial ignorance, your reply has led me to the answer.

By using a combination of positive values in the top and bottom margins in my class styles, I can achieve the desired affect of near total control of leading between paragraphs and have it work in IE6 as well as other browsers.

I was using a negative top margin value in one class style to "invade" or overlap the large bottom margin of the preceding paragraph, which obviously doesn't work properly in all browsers, though it does in some.

By applying a 0 bottom margin to my headline class style, I can then apply any positive number to the top margin in the body class style to control the leading between the headline and body copy without using negative values. That effectively "moves" the bottom margin border of the headline up so that I'm not overlapping text areas with one another.

Since I want to control leading between different paragraphs differently, I don't want to apply margin controls to a the <p> tag selector, but the answer is still the same.

Thanks for your help!!!