Forum Moderators: open

Message Too Old, No Replies

Need help on <h2> tag

         

sirkei

10:01 pm on May 9, 2005 (gmt 0)

10+ Year Member



Hi,

Can anyone explain whether this is correct?

<center>
<u><h2 style="margin-top: 0; margin-bottom: 0">My Page</h2></u>
keywords, keywords, more keywords
</center>&nbsp;

I would like to know whether using style="margin-top: 0; margin-bottom:0 does damage anything at all. because it seems like does not fit the w3 validator.

tedster

10:05 pm on May 9, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



There's no problem with the style atttribute - but <u> is long deprecated and so is the <center> tag. Try this:

<h2 style="margin-top:0;margin-bottom:0;text-decoration:underline;text-align:center;">My Page</h2>