note 56518 added to function.hexdec
| From: | nihaopaul at nihaopaul dot com | Date: | Tue, 06 Sep 2005 03:47:14 +0000 |
| Subject: | note 56518 added to function.hexdec | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-94777@lists.php.net to get a copy of this message | ||
function querystring_output($array) {
foreach($array as $key => $value) {
$qs = split("=", $value);
if ($qs[0] == 'msg') {
$qsary = split("%", $qs[1]);
foreach($qsary as $key => $value) {
if ($qsary[$key]) {
$output .= $key . '=> ' . hexdec($value) .
'<br>'."\n";
}
}
}
}
return $output;
}
$_content .= querystring_output(split("&", $_SERVER['QUERY_STRING']));
all its missing is to turn that hex into html unicode so it can be displayed on a page without
changing the character encoding.
----
Manual Page -- http://www.php.net/manual/en/function.hexdec.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+56518
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes&reason=non-english
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56518&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+56518&report=yes
Search -- http://master.php.net/manage/user-notes.php