[wp-trac] [WordPress Trac] #19803: get_previous_posts_link: Capital HTML entity
WordPress Trac
wp-trac at lists.automattic.com
Wed Jan 11 08:01:40 UTC 2012
#19803: get_previous_posts_link: Capital HTML entity
--------------------------+------------------------------
Reporter: ounziw | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Formatting | Version: 3.3.1
Severity: minor | Resolution:
Keywords: |
--------------------------+------------------------------
Description changed by scribu:
Old description:
> get_previous_posts_link (located in wp-includes/link-template.php ) has a
> regular expression at line 1569
> preg_replace( '/&([^#])(?![a-z]{1,8};)/', '&$1', $label )
>
> This replaces ''⇐'' into ''⇐'', hence ''⇐'' is not
> allowed as a linktext. (html entites with capital letter(s) disallowed)
>
> get_next_posts_link (also located in wp-includes/link-template.php ) has
> a regular expression at line 1498
> preg_replace('/&([^#])(?![a-z]{1,8};)/i', '&$1', $label)
>
> This does not replace ''⇐''
>
> I propose to use
> preg_replace('/&([^#])(?![a-z]{1,8};)/i', '&$1', $label)
> both get_next_posts_link and get_previous_posts_link
New description:
get_previous_posts_link (located in wp-includes/link-template.php ) has a
regular expression at line 1569
{{{
preg_replace( '/&([^#])(?![a-z]{1,8};)/', '&$1', $label )
}}}
This replaces ''⇐'' into ''⇐'', hence ''⇐'' is not
allowed as a linktext. (html entites with capital letter(s) disallowed)
get_next_posts_link (also located in wp-includes/link-template.php ) has a
regular expression at line 1498
{{{
preg_replace('/&([^#])(?![a-z]{1,8};)/i', '&$1', $label)
}}}
This does not replace ''⇐''
I propose to use
{{{
preg_replace('/&([^#])(?![a-z]{1,8};)/i', '&$1', $label)
}}}
both get_next_posts_link and get_previous_posts_link
--
--
Ticket URL: <http://core.trac.wordpress.org/ticket/19803#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list