[wp-trac] [WordPress Trac] #10823: Bad handling of ampersand in post titles
WordPress Trac
wp-trac at lists.automattic.com
Wed Apr 7 19:00:23 UTC 2010
#10823: Bad handling of ampersand in post titles
---------------------------+------------------------------------------------
Reporter: Commeuneimage | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.0
Component: Formatting | Version: 2.8.4
Severity: minor | Keywords: ampersand the_title_attribute htmlspecialchars
---------------------------+------------------------------------------------
Comment(by mdawaffe):
I cannot confirm 1. the_title_attribute() does correctly turn ampersands
into HTML entities for me.
I can confirm 2.
It comes from the following line in sanitize_title_with_dashes().
{{{
$title = preg_replace('/&.+?;/', '', $title); // kill entities
}}}
Fixing this could generate more bugs since the output is used in
permalinks.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/10823#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list