Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 500
  • Last Modified:

Strange Double Line Height when using H2 tag

I have just modified one of my pages slightly so that some text links are enclosed in H2 tags.  I have styled the H2 tags with the following code.

h2 {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF}
h2 a:link {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF}
h2 a:active {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF}
h2 a:visited {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF}
h2 a:hover {font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF; text-decoration:underline}

All of the text appears in DIV containers that are styled with the folloing CSS.

.home_links {width:145px; height:20px; background-color:#010167; font-family:Verdana, Arial, Helvetica, sans-serif; font-size:12px; color:#FFFFFF; border:1px solid color:#999999; line-height:20px}

Each DIV is in a TD - <TD align="right" height="20">

Strangely, in IE my DIV appears twice the height of the line-height, i.e 40px when I am only looking for a DIV height of 20px.

In Netscape / FF it appears Okay.

Can any body make any suggestions in relation to correcting this?

Thanks in advance,

Andrew.
0
andrewmilner
Asked:
andrewmilner
1 Solution
 
nltechCommented:
hey, i know an 'andrew milner' ;)

headings and paragraphs have margins by default. have you tried adding: margin-top:0;margin-bottom:0;  ?

if that doesn't do the trick, can you post a little additional code (html & css)?
0
 
andrewmilnerAuthor Commented:
That's done the trick nltech.  Thanks for your speedy resolve.

Perhaps you know me :-0.  Where you from?

Thanks again.

Andrew.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now