[wp-trac] [WordPress Trac] #20772: remove_accents() improvements for Chinese pinyin permalinks

WordPress Trac wp-trac at lists.automattic.com
Tue May 29 07:57:40 UTC 2012


#20772: remove_accents() improvements for Chinese pinyin permalinks
--------------------------+------------------------------
 Reporter:  bolo1988      |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  I18N          |     Version:  3.3.2
 Severity:  normal        |  Resolution:
 Keywords:                |
--------------------------+------------------------------

Comment (by bolo1988):

 {{{
                 $pinyin_in = array(
                         chr(199).chr(142) => 'a',
                         chr(199).chr(144) => 'i',
                         chr(199).chr(146) => 'o',
                         chr(199).chr(148) => 'u',
                         chr(199).chr(154) => 'u',
                 );
                 $output = str_replace(array_keys($pinyin_in), $pinyin_in,
 $string);

 }}}

 This code can fixed the problem

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/20772#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list