|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-10-03 18:40 UTC] moriyoshi@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 14:00:01 2025 UTC |
Description: ------------ Something wrong with result array from unpack. var_dump prints correct content. But when I try to access directly to index, that reports "undefined offset". Reproduce code: --------------- $a=unpack('C3',pack("H6","123456")); var_dump($a); $k=array_keys($a); var_dump($k); $i=$k[0]; print $a[$i]; Expected result: ---------------- Expected result of line 9 is: 18 Actual result: -------------- Undefined offset: 1 in 1.php on line 9