Changes between Version 1 and Version 2 of Ticket #33121, comment 16
- Timestamp:
- 10/11/2018 03:55:00 PM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #33121, comment 16
v1 v2 3 3 Looking at `data--invaild="gone"` and `data-also-invaild-="gone"`, it seems having two hyphens or a hyphen as last char of the data-* attribute name is valid per https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/data-* and https://www.w3.org/TR/REC-xml/#NT-Name. Also seems quite a few chars are valid there, but still thinking we should only support `a-z0-9_-`. 4 4 5 Also `preg_match( '/^' . preg_quote( $prefix ) . '(-[a-z0-9_]+)*$/', $name_low )` would mean we don't allow attribute manes withtwo hyphens like `data-wp-id` (which is somewhat common).5 Also `preg_match( '/^' . preg_quote( $prefix ) . '(-[a-z0-9_]+)*$/', $name_low )` would mean we don't allow attribute manes containing two hyphens like `data-wp-id` (which is somewhat common).