note 25505 added to function.array-push

From: Date: Thu, 26 Sep 2002 05:42:45 +0000
Subject: note 25505 added to function.array-push
Groups: php.notes 
Request: Send a blank email to php-notes+get-37264@lists.php.net to get a copy of this message
... failing that, you can use the old IE4 javascript hack I discovered years ago for naming array keys... prefix them with a letter instead of a straight integer. ie., $foo['a999'] instead of $foo[999]. Okay, so doing this you'll have to substr() on the keys to return the integers, but it's another way to guarantee your array's not loaded to sizeof() = 999 if you've only got a handful of keys/items -- http://www.php.net/manual/en/function.array-push.php http://master.php.net/manage/user-notes.php?action=edit+25505 http://master.php.net/manage/user-notes.php?action=delete+25505 http://master.php.net/manage/user-notes.php?action=reject+25505

« previous php.notes (#37264) next »