WordPress.org

Make WordPress Core

Opened 3 years ago

Last modified 3 years ago

#39847 new defect (bug)

force_balance_tags not properly balancing < with <strong> and </strong>

Reported by: jpmerx Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.7.2
Component: Formatting Keywords:
Focuses: ui Cc:
PR Number:

Description

Given following HMTL code which includes the \[ and \] Latex delimiters:

\[<\] <strong>We</strong>

the output of force_balance_tags is

\[<\] <strong>We

which is not correct as the bold tags are unbalanced. Expected output should be the input string.

Change History (1)

#1 @jpmerx
3 years ago

  • Summary changed from force_balance_tags not properly balancing < in \[\] block to force_balance_tags not properly balancing < with <strong> and </strong>

I found an even simple string producing the error.

For following HMTL code which includes the < symbol:

< <strong>We</strong>

the output of force_balance_tags is

< <strong>We

which is not correct as the bold tags are unbalanced. Expected output should be the input string.

Last edited 3 years ago by jpmerx (previous) (diff)
Note: See TracTickets for help on using tickets.