Forum Moderators: not2easy
in the .css file I put this:
/* Solution to make hr appear to have color in non IE browsers */
table.hr { border-style:solid; border-color:#600030; border-width:1px; }
and in the page itself I put this:
<table border="0" width="100%" class="hr" cellpadding="0" cellspacing="0">
<tr>
<td bgcolor="#600030"><img src="img/blank.gif" width="1" height="1" border="0"></td>
</tr>
</table>
I now have what looks like an hr in all browsers. Sure it's more code but I like it to look the same in all browsers if possible
.bt{border-top:.05em solid #999;padding:.5em 0 0 0;}
And then assigning that to the block level element that gets a horizontal rule above it.
P.S. Works fine in those browsers I tested it in and it validates. It is not semantically correct but it beats dealing with the hacks to accommodate the different browser interpretations of <hr>.
<style type="text/css">
h2.sectionheader {border-top: 1px solid #c00; padding-top: 0.5em}
p.colophon {border-top: 2px solid #999; padding-top: 0.35em}
</style>
[...]
<h2 class="sectionheader">Post-Husserlian Widget Theory</h2>
[...]
<p class="colophon">
Copyright © 2003 Center on Widget Studies, All Rights Reserved.
</p>
Presentation aspects of <hr> were deprecated in HTML 4.01, although they are not invalid. IIRC in XHTML the attribute should be expressed as noshade="noshade" and you also need to close the tag with a />.
<div class="hr"><hr /></div>
then in the CSS:
.hr{
display: block;
height: 2px;
line-height: 2px;
background-color: red;
color: #000;
width: 80%;
margin: 0px auto 10px auto;
padding: 0;
}
.hr hr{display: none;}
this will 'remove' the default <hr> from the screen but leaves you with a <div> which you can style accordingly (put a background graphic in it if you want ;)), but on non CSS browsers you will still get an <hr>
Suzy