Why do headers do this?

Before I start I know I have to come up to speed with HTML5. I know there is an answer to this problem and that’s why I am h ere. :wink:

Why is it that when I use any header tags <h4></h4> it does not allow the header to valign=“top” to the top of the table. And why does it push the plain text so much further down?


I’m struggling to visualise what the problem is, you might need to give us a particular example of what you’re doing and what you don’t like about the result.

He was probably was getting confused and didn’t understand normally for tables you’d use the TH element - table header cell.

HTML is a markup language. It describes what things are, but says nothing about how they look. That is the realm of CSS.

The reason in this case is that heading elements usually have a top margin specified in the user agent style sheet. Set td h4 {margin-top:0} to remove it. (Not that I understand why you need headings in a table cell.)

have you tried using CSS? apply vertical-align:top to the table cell