[wp-trac] [WordPress Trac] #63824: button is not a self-closing HTML element and needs a closing tag
WordPress Trac
noreply at wordpress.org
Wed Aug 13 11:53:42 UTC 2025
#63824: button is not a self-closing HTML element and needs a closing tag
--------------------------+----------------------
Reporter: kkmuffme | Owner: (none)
Type: defect (bug) | Status: closed
Priority: normal | Milestone:
Component: Media | Version: 4.8
Severity: trivial | Resolution: invalid
Keywords: | Focuses:
--------------------------+----------------------
Changes (by ocean90):
* keywords: has-patch changes-requested =>
* status: reopened => closed
* resolution: => invalid
Comment:
In jQuery, `$( '<element />' )` is just a shorthand for `$(
'<element></element>' )`. jQuery will not add `<element />` to the DOM,
instead it uses `createElement( element )` under the hood.
See
https://github.com/jquery/jquery/blob/9c84195b9445645ba22f1c88d464d0b7d5ba22dd/src/core/parseHTML.js#L34
and
https://github.com/jquery/jquery/blob/9c84195b9445645ba22f1c88d464d0b7d5ba22dd/src/core/var/rsingleTag.js#L3C25-L3C90.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63824#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list