An open API service indexing awesome lists of open source software.

https://github.com/nggit/php-xmlentities

Convert all Unicode characters and character references to numeric character references
https://github.com/nggit/php-xmlentities

Last synced: about 1 month ago
JSON representation

Convert all Unicode characters and character references to numeric character references

Awesome Lists containing this project

README

          

# PHP xmlentities
**Tip:** Rename this `md` file to `php` to test it on your web server.

© © with ❤ ';
$encoded = Nggit\PHPXMLEntities\NCR::encode($str);

### These are portable ASCII characters
echo $encoded;
// Source view:
//

© © with ❤


exit;

?>

That's it! This library doesn't use the `mbstring` or `iconv` extension for better compatibility.