Skip to content

Commit

Permalink
Fix #11011: Can't add custom fields with UTF8 names
Browse files Browse the repository at this point in the history
Custom fields with UTF8 names could not be created or managed without
errors being experienced. This was due to use of ASCII string functions
instead of UTF8 functions.

Signed-off-by: David Hicks <hickseydr@optusnet.com.au>
  • Loading branch information
watergad authored and davidhicks committed Feb 28, 2011
1 parent 0faec07 commit 3eff319
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/columns_api.php
Expand Up @@ -358,7 +358,7 @@ function column_get_title( $p_column ) {
* @access public
*/
function columns_ensure_valid( $p_field_name, $p_columns_to_validate, $p_columns_all ) {
$t_columns_all_lower = array_map( 'strtolower', $p_columns_all );
$t_columns_all_lower = array_map( 'utf8_strtolower', $p_columns_all );

# Check for invalid fields
foreach( $p_columns_to_validate as $t_column ) {
Expand Down Expand Up @@ -394,7 +394,7 @@ function columns_ensure_valid( $p_field_name, $p_columns_to_validate, $p_columns
* @access public
*/
function columns_remove_invalid( $p_columns, $p_columns_all ) {
$t_columns_all_lower = array_values( array_map( 'strtolower', $p_columns_all ) );
$t_columns_all_lower = array_values( array_map( 'utf8_strtolower', $p_columns_all ) );
$t_columns = array();

foreach( $p_columns as $t_column ) {
Expand Down

0 comments on commit 3eff319

Please sign in to comment.