note 79855 added to function.arsort

From: Date: Sat, 15 Dec 2007 22:21:21 +0000
Subject: note 79855 added to function.arsort
Groups: php.notes 
Request: Send a blank email to php-notes+get-133602@lists.php.net to get a copy of this message
A lot of people seem to trip up on this and ask me questions as to debugging. Bear in mind that this returns boolean, and does not return an array of affected items. $array = array("One"=>1, "Three" => 3,"Two" =>2); print_r(asort($array)); If successful, will return 1, and error if there is a string used. Useful to note so then people stop asking me :D ---- Server IP: 194.145.210.4 Probable Submitter: 86.151.223.154 ---- Manual Page -- http://www.php.net/manual/en/function.arsort.php Edit -- https://master.php.net/note/edit/79855 Del: integrated -- https://master.php.net/note/delete/79855/integrated Del: useless -- https://master.php.net/note/delete/79855/useless Del: bad code -- https://master.php.net/note/delete/79855/bad+code Del: spam -- https://master.php.net/note/delete/79855/spam Del: non-english -- https://master.php.net/note/delete/79855/non-english Del: in docs -- https://master.php.net/note/delete/79855/in+docs Del: other reasons-- https://master.php.net/note/delete/79855 Reject -- https://master.php.net/note/reject/79855 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#133602) next »