[Webkit-unassigned] [Bug 148863] New: A label element not in a document should not label an element in a document

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Sep 4 18:18:34 PDT 2015


            Bug ID: 148863
           Summary: A label element not in a document should not label an
                    element in a document
    Classification: Unclassified
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: HTML DOM
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: rniwa at webkit.org
                CC: cdumez at apple.com, webkit-bug-importer at group.apple.com

See https://html.spec.whatwg.org/multipage/forms.html#the-label-element

"The for attribute may be specified to indicate a form control with which the caption is to be associated. If the attribute is specified, the attribute's value must be the ID of a labelable element in the same Document as the label element. If the attribute is specified and there is an element in the Document whose ID is equal to the value of the for attribute, and the first such element is a labelable element, then that element is the label element's labeled control."

When a label element is not in the document, it should not be associated with any form control element.

This bug was found by the newly added test:

You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150905/ba085151/attachment.html>

More information about the webkit-unassigned mailing list