I’m developing a CMS for a customer and he needs to edit stuff and use special characters such as ç and ®. However, I don’t want him to have to enter the character codes like ®. Does anyone knows a good way to automatically convert those characters using PHP?
I’m developing a CMS for a customer and he needs to edit stuff and
Share
You can use htmlentities() to do that.
To turn entities back to readable text, use html_entity_decode():
If you’re not using unicode, omit the charset name or give the correct charset.