flyx
flyx

Reputation: 39678

How to interpret "permitted parent elements" of HTML tags

The MDN documentation on <embed> tells me the following:

Permitted parent elements: Any element that accepts embedded content.

Now I'm wondering, which elements accept embedded content? I checked the documentation on <div>: It only allows flow content. I didn't find any element that explicitly accepts embedded content. I guess I'm missing something. Is this some implicit rule? Where is it defined whether some element accepts embedded content?

Upvotes: 1

Views: 205

Answers (2)

robertc
robertc

Reputation: 75707

Embedded content is a subset of phrasing content, which is itself a subset of flow content. There is a diagram in the spec:

Venn diagram showing the relationships between HTML5 content types

Upvotes: 1

gpgekko
gpgekko

Reputation: 3606

If you click on flow content, it will bring you to a page that says the following:

Elements belonging to the flow content category typically contain text or embedded content.

Which seems to suggest that any element accepting flow content will accept embedded content. Quickly scanning the specs seems to confirm this.

Though I have to admit, it's all written a bit vague.

Upvotes: 1

Related Questions