Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #28058, comment 1


Ignore:
Timestamp:
04/29/2014 06:03:57 PM (10 years ago)
Author:
jesin
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #28058, comment 1

    initial v1  
    22
    33That regex (`/[^a-z0-9_\-]/`) removes non-English characters.
     4
     5As a workaround this piece of string can be omitted from sanitization.
     6
     7{{{
     8add_filter( 'sanitize_key', 'utf_untouched', 10, 2 );
     9
     10function utf_untouched( $key, $raw_key ) {
     11        if ( 'pa_資料庫版本' == $raw_key )
     12                return $raw_key
     13
     14        return $key
     15}
     16}}}