Opened 2 years ago
Closed 2 years ago
#56430 closed defect (bug) (duplicate)
sanitize_text_field strips out valid characters
Reported by: | vaakash | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 6.0.1 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
sanitize_text_field
function strips out valid characters like for example %de
from %description%
I cannot find other combinations of such but noticed this issue when a user reported for my plugin. Not sure if there are more.
Example:
<?php echo sanitize_text_field( 'Hello %description% world' ); ?>
Outputs
Hello scription% world
Change History (1)
Note: See
TracTickets for help on using
tickets.
Hi there, welcome to WordPress Trac! Thanks for the ticket.
This appears to be a manifestation of the issue previously reported in #31777, let's continue the discussion there.