In accordance with W3C and WHATWG, the permitted content is any element characterized as phrasing content, which is the same as permitted for the element <p>
.
However, elements that are labelled (labelable), just as <input>
, with one particular exception. The element <label>
has the attribute for
that may receive the id
of <input>
to which it is associated. In this case, the <label>
already has a control entry and therefore cannot have other in its content. So, if you use the attribute for
, cannot define <input>
in its content.
Already, when the attribute for
is not used, will be considered as control input the first labelable field of its content. In this case, the first <input>
what to find inside <label>
. This way, not using the attribute, you can have one, and only one, element labelable as child.
The elements characterized as phrasing content sane:
a, abbr, area (if descended from a <map>
), audio, b, bdi, bdo, br, button, canvas, cite, code, data, datalist, del, dfn, em, embed, i, iframe, img, input, ins, kbd, label, link (if allowed in the body), map, mark, mathml Math, meta (if you have the attribute itemprop
), meter, noscript, Object, output, picture, Progress, q, ruby, s, Samp, script, select, slot, small, span, Strong, sub, sup, svg, template, textarea, time, u, var, video, wbr, Autonomous custom Elements and text.
As well as the labelable elements are:
button, input (if not of the type Hidden), meter, output, Progress, select, textarea
I don’t know if it’s right, but look here
– Pedro Augusto