What is the PHP enye (“ñ”) version conversion

When you live in the Philppines, you will probably encounter names and places that have the enye (“ñ”) symbol. For us developers, it comes out diferently especially in databases and labels.

For the database, it comes out as DASMARIñAS CAVITE with the character “ñ”

Once you put this character in your code, it will translate to enye (“ñ”).

What i use when a user encodes it, is to convert it using string replace.

$mystring = str_replace("DASMARI?","DASMARIñ",$mystring);
$mystring = str_replace("DASMARI�","DASMARIñ",$mystring);

Hope this helps someone out there in the web.

Coffee Cup

Leave a Reply

Your email address will not be published. Required fields are marked *