-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Characters for greater than and less than are not encoded as entities in attribute values #15636
Comments
I don't think it's entirely a regression of #9963, in that the element serializer itself is not the culprit, and it does still encode the characters. I think the issue is a combination of var d = document.createElement( 'div' );
d.innerHTML = '<p><abbr title="1 > 2">False</abbr> and <abbr title="1 < 2">True</abbr></p>';
console.log( d.innerHTML );
// "<p><abbr title="1 > 2">False</abbr> and <abbr title="1 < 2">True</abbr></p>" |
So the blame lies entirely with |
Technically it always has 😆 #9963 was always a bandaid workaround because nobody dared touch the texturize function. |
Anything actionable? Is this still an issue? |
@ellatrix This is still an issue as of v7.1.0-rc.1. |
When adding
>
or<
into an attribute value as follows:The serializer forces them to be
>
and<
respectively.This gets rendered by WordPress as:
The “False and” text is erroneously consumed be the attribute:
In this case, it seems to be a problem with
wptexturize()
, as it is converting the attribute closing"
into″
.But if the block serializer output
>
as>
then this symptom could be avoided.Possible regression after #9963.
Relates to #9915, #8779, #12683.
Tested in v5.7.0-rc.1.
The text was updated successfully, but these errors were encountered: