anishmsry — 2012-01-19T02:05:01-05:00 — #1
I used to think that all block-level elements can contain block elements & inline elements.
In [reference.sitepoint.com/html/h1, [URL="http://reference.sitepoint.com/html/h6"]reference.sitepoint.com/html/h6 , [URL="http://reference.sitepoint.com/html/p"]reference.sitepoint.com/html/p](http://reference.sitepoint.com/html/h1) etc. it's mentioned:
This element may contain any text content, but it can’t include any block-level elements: only inline or phrase elements can be included.
When I checked, I saw that <h1>, <h2>....<h6>, <p>, <li> inside <dir> or <menu> cannot contain block-level elements.
Are there any other block elements that cannot contain block elements?
kohoutek — 2012-01-19T02:31:39-05:00 — #2
dt is another one I can think of.
anishmsry — 2012-01-19T03:13:30-05:00 — #3
is not validating
anishmsry — 2012-01-19T03:23:03-05:00 — #4
Note that it can’t contain any block-level elements—not even p or heading elements such as h1, h2, and so on. It can only contain text.
xhtmlcoder — 2012-01-19T05:21:11-05:00 — #5
The answer to the question partially depends upon whether you are using either: Strict or Transitional HTML 4.01 markup?
Since it actually differs on what is allowed within a block-level element itself.
Thus assuming Strict others may include: ADDRESS, FIELDSET, PRE there are other deprecated tag examples and some that obviously follow 'specific rules' e.g. like UL having a LI but I won't bother with those, etc. Maleika already covered definition lists and you spotted some others at that SP refrence too.
anishmsry — 2012-01-19T19:52:06-05:00 — #6
I'm concerned about Strict mode.
Where to find more details? Sitepoint's reference on ADDRESS, FIELDSET, PRE doesn't mention anything about this.
Where do you get such info?
xhtmlcoder — 2012-01-20T05:27:25-05:00 — #7
From the horse's mouth: http://www.w3.org/TR/html401 rather than a book it's explained in the W3C TR http://www.w3.org/TR/html401/index/elements.html even though its not light reading.