Jump to content

Recommended Posts

An easy solution to this is to convert the characters to HTML entities, using the htmlentities function. You can then use html_entity_decode to decode them, if needed. If you're outputting to a web page it's better to leave them as HTML entities however.

Thanks for the answer but after  htmlentities()  and html_entity_decode() the ìíóò into the csv, I still get funny symbols.

 

and the html translate is wrong aswell, example I get for í :

 

ó    which I support to get í but I get ó

 

Any thought?

There really is only so much you can do to help a user, you can't be responsible for their retardedness.

 

but I guess MrAdam has a good point, not sure if it will work..

 

$decoded_string = html_entity_decode($string, ENT_QUOTES, 'UTF-8');

cannot yet handle MBCS in html_entity_decode()

 

but I rewrite the function: $utf8_encode = utf8_encode(html_entity_decode($string));

according to http://php.net/manual/en/function.html-entity-decode.php

Still funny symbol showing

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.