note 89355 added to function.array-multisort

From: Date: Wed, 04 Mar 2009 14:53:35 +0000
Subject: note 89355 added to function.array-multisort
Groups: php.notes 
Request: Send a blank email to php-notes+get-151456@lists.php.net to get a copy of this message
You have one small bug in manual, this: <?php $tbl = array ( array ("10", 100, 100, "a"), array (1, 3, "2", 1) ); array_multisort ($tbl[0], SORT_ASC, SORT_STRING, $tbl[1], SORT_NUMERIC, SORT_DESC); var_dump($tbl); ?> will not show what You show, I mean: array(2) { [0]=> array(5) { [0]=> string(2) "10" [1]=> int(100) [2]=> int(100) [3]=> int(11) [4]=> string(1) "a" } [1]=> array(5) { [0]=> int(1) [1]=> int(3) [2]=> string(1) "2" [3]=> int(2) [4]=> int(1) } } but: array(2) { [0]=> array(4) { [0]=> string(2) "10" [1]=> int(100) [2]=> int(100) [3]=> string(1) "a" } [1]=> array(4) { [0]=> int(1) [1]=> int(3) [2]=> string(1) "2" [3]=> int(1) } } It's litle bug, but it's. Best regards. ---- Server IP: 82.177.164.100 Probable Submitter: 83.145.134.242 (proxied: 91.207.149.2) ---- Manual Page -- http://www.php.net/manual/en/function.array-multisort.php Edit -- https://master.php.net/note/edit/89355 Del: integrated -- https://master.php.net/note/delete/89355/integrated Del: useless -- https://master.php.net/note/delete/89355/useless Del: bad code -- https://master.php.net/note/delete/89355/bad+code Del: spam -- https://master.php.net/note/delete/89355/spam Del: non-english -- https://master.php.net/note/delete/89355/non-english Del: in docs -- https://master.php.net/note/delete/89355/in+docs Del: other reasons-- https://master.php.net/note/delete/89355 Reject -- https://master.php.net/note/reject/89355 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#151456) next »