We help IT Professionals succeed at work.

hr top  margins difference ie and firefox

thatelvis
thatelvis asked
on
Medium Priority
496 Views
Last Modified: 2011-10-03
Hello,
I am using an HR tag, (horozontal rule) I am using the following css too

.myruler {
width: 100%; background-color:#CC0033;
color:#000000;
height: 1px;
border: none;
margin-top: -4px; padding: 0px;
}

what can I do to maintain the same hr top margin with both ff and ie. I want my hr to be directly under my text at 100% ,


<div style="margin-left:12px; margin-right: 12px;"> Welcome!
          <hr class="myruler"></hr>
          </div>


regards

kenny
Comment
Watch Question

Top Expert 2006
Commented:
HR has bad cross-browser support.  Use a border instead:

<div style="border-bottom: 1px solid #CC0033; margin-left:12px; margin-right: 12px;"> Welcome!
</div>

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
thanks I got there in the end. i had tried everything poss with the hr. any way a is well now.

cheers

Kenny
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.