0

Is there any possible way of doing this in PHP? Eg convert the word Québec

$str = 'Québec';

echo convert($str);

result:

Quebec
Nick Shears
  • 1,103
  • 1
  • 13
  • 30
  • These are actually accented letters, that may have made it tougher for you to search for! Check out the answer here - http://stackoverflow.com/questions/3371697/replacing-accented-characters-php - basically, you can use [iconv](http://php.net/manual/en/book.iconv.php) to replace them. – admdrew Nov 15 '13 at 17:35

1 Answers1

0

Those are called diacritics (or accents). The process of converting some text from one script to another (e.g. one with diacritics to one without) is called transliteration and PHP has a module for performing it.

You probably want something like:

transliterator_transliterate('Any-Latin; Latin-ASCII', $your_input);
Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335