Ignore:
Timestamp:
09/04/12 22:03:33 (7 years ago)
Author:
rvelices
Message:

bug 2735: fix/improve non latin language tags

  1. non latin tags (greek/cyrillic...) are not sorted case-insesitive and group by letter view in tag list is not case insesitive
  2. quick searching tag names does not perform correctly accent folding (e.g. Köln and Koln do not match) and case insesitivity for non latin letters
  3. missing from remove_accents characters in romanian language (Latin Extended-B) ? c8 98 = LATIN CAPITAL LETTER S WITH COMMA BELOW ? c8 99 = LATIN SMALL LETTER S WITH COMMA BELOW ? c8 9a = LATIN CAPITAL LETTER T WITH COMMA BELOW ? c8 9b = LATIN SMALL LETTER T WITH COMMA BELOW
  4. str2url allow non latin letters in output only if the input does not contain any valid lating letter/digit. we should always allow non latin letters in output
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/functions_metadata.inc.php

    r12922 r17748  
    9191    // how to detect it so a plugin should do the trick. 
    9292    $value = trigger_event('clean_iptc_value', $value); 
    93     $is_utf8 = seems_utf8($value); 
    94     $value = convert_charset( $value, 
    95       $is_utf8 ? 'utf-8' : 'iso-8859-1', 
    96       get_pwg_charset() ); 
     93    if ( ($qual = qualify_utf8($value)) != 0) 
     94    {// has non ascii chars 
     95      $value = convert_charset( $value, 
     96        $qual>0 ? 'utf-8' : 'iso-8859-1', 
     97        get_pwg_charset() ); 
     98    } 
    9799  } 
    98100  return $value; 
Note: See TracChangeset for help on using the changeset viewer.