note 3552 modified in count by ronabop

From: Date: Wed, 04 Oct 2000 14:39:27 +0000
Subject: note 3552 modified in count by ronabop
Groups: php.notes 
Request: Send a blank email to php-notes+get-6021@lists.php.net to get a copy of this message
This is taken from sganer@expio.co.nz comments on the sizeof() function: If some elements in your array are not set, then sizeof() and count() will not return the index of the last element, but will return the number of set elements. To find the index of the last element in the array: end($yourArray); $index = key($yourArray); ... Where $yourArray is the array you want to find the last index ($index) of. http://www.php.net/manual/function.count.php

« previous php.notes (#6021) next »