Erfan Shirazi wrote:
I have tried every encoding which could be found in:
http://www.php.net/manual/en/ref.mbstring.php
But nothing seems to work, I don't have any problems displaying the
funny chars in the browsers, there are some encodings which works fine
for that, the problem is when I save it to a file using fwrite().
there is no problem - you are writing to the file exactly what you asked for -
namely
a string changed to uppercase with all characters that have html entities
converted as
such.
have you read the manual? rather than just stare at it.
$str = "Asunción";
var_dump( mb_strtoupper($str, "ISO-8859-1"), mb_convert_case($str,
MB_CASE_UPPER) );
if I run that code (on the cmd line, but that should make no difference) I get:
string(8) "ASUNCIÓN"
string(8) "ASUNCIÓN"
as you see there are no html entities BECAUSE I DIDN'T ASK FOR THEM.
oh and stop cross-posting.
Michael Wallner wrote:
Hi Erfan Shirazi, you wrote:
Does anybody now what I can do in order to make the string into capital
letters, be able to save it to a file and looking as it should look,
that is: Asunción and not ASUNCIÓN?
1. Specify the charset the string is in http://php.net/mb_strtoupper
2. Specify the charset you are using in your HTML page
Regards,
--
PHP Internationalization Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php