Man In Tan Posted April 16, 2012 Share Posted April 16, 2012 I'm trying to build a substitution cipher class, but character encodings are getting in the way. I want to make use of all one bit UTF-8 characters, as well as the regular space character. However, when I send certain characters to PHP through this form, they get interpreted as multi-byte characters. For example, if I send character 255 (ÿ), it gets interpreted as the two characters "ÿ". Any idea haw to fix this? <form action="filemanager.php?file=%2F0gb.us%2Ftest.php" method="post" accept-charset="UTF-8"><input type="hidden" name="function" value="file_put_contents" /><textarea rows="64" cols="64" name="file"></textarea><input type="submit" value="file_put_contents()" /></form> EDIT: Never mind. I didn't understand how UTF-8 actually works. There are no characters at the code points 128 through 255. Characters requiring more than seven bits to express seem be in the two byte range. My bad. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.