Created
October 28, 2013 06:12
-
-
Save steppefox/7192097 to your computer and use it in GitHub Desktop.
String to Ascii
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function string_to_ascii($string) | |
| { | |
| $ascii = array(); | |
| for ($i = 0; $i < strlen($string); $i++) | |
| { | |
| $ascii[] =$string[$i].':'.ord($string[$i]); | |
| } | |
| return(implode(' ', $ascii)); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment