RE: Simple array question, part 2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[snip]
I have a $data array like this:
    [0] => 158
    [1] => 169926
    [2] => 169931
    [3] => 169932
    [4] => 169933
then when i delete the first one     ([0] => 158) it becomes like this:
[1] => 169926
    [2] => 169931
    [3] => 169932
    [4] => 169933

how do I get it to sort again from 0,1,2,3 etc?

I tried sort(), ksort(),reset() etc....but it still shows as starting
from 1
instead of resorting the keys starting from 0

what function should i lookup/use?
[/snip]

http://www.php.net/array_pop

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux