Tools, FAQ, Tutorials:
Converting Character to ASCII Value in PHP
How To Convert a Character to an ASCII Value?
✍: FYIcenter.com
If you want to convert characters to ASCII values, you can use the ord() function, which takes the first character of the specified string, and returns its ASCII value in decimal format. ord() complements chr(). Here is a PHP script on how to use ord():
<?php print(ord("Hello")."\n"); print(chr(72)."\n"); ?>
This script will print:
72 H
⇐ Generating Character from ASCII Value in PHP
2016-10-13, 3325🔥, 0💬
Popular Posts:
How To Set session.gc_divisor Properly in PHP? As you know that session.gc_divisor is the frequency ...
How to read RSS validation errors at w3.org? If your RSS feed has errors, the RSS validator at w3.or...
Why I am getting "The Windows SDK version 8.1 was not found" error, when building my C++ application...
How to Install Docker Desktop on Windows 10? You can follow this tutorial to Install Docker Desktop ...
What is EPUB 2.0 Metadata "dc:identifier" Element? EPUB 2.0 Metadata "dc:identifier" is a required m...