$txt = "björk"; $txt = strtr($txt, "ÁÉÍÓÚÑÀÈÌÒÙÄËÏÖÜÂÊÎÔÛáéíóúñàèìòùäëïöüâêîôûç", "aeiounaeiouaeiouaeiouaeiounaeiouaeiouaeiouc"); echo $txt; // Returns "bjork"
-----Original Message----- From: Chris McCluskey [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 18, 2003 7:03 PM To: [EMAIL PROTECTED] Cc: Flint Doungchak; Ethan Nelson Subject: [PHP] ASCII/UNICODE Character Translation Comparison in Strings Hello, I was wondering if there are any native PHP functions that will acomplish what I have set out to do here: I have an issue where I would need to compare international characters, for instance i would want "björk" to match "bjork", i would want ô,ö, and ò to match o; ñ, Ñ to match n. etc... I could just create a function that would do this, and I already have ideas about how to go about this, but before i start coding, i want to make sure there isn't something that PHP does already that could replace what i'm trying to do here. Thanks (yes, i googled already) ;-) -Chris ----------------------------------- _ _ _ _ |'|(_)|_)(_)|_(_)`-, * * * ------------------------------------ Chris McCluskey Web Applications Engineer Modulus, LLC 1720 Willow Creek Circle, Suite 520 Eugene, OR 97402 Email: [EMAIL PROTECTED] Voice: +1 (541) 434-1024 Web..: http://www.modulusgroup.com <http://www.modulusgroup.com/> ============================================ The contents of this transmission may be confidential in nature and should be directed only to the person to whom it is addressed. Do not read, copy, or disseminate this material unless you are the intended recipient. If this transmission reached you in error, please forward the e-mail to the sender to advise, then destroy the transmission you received. Thank you. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php