create array
Posted: Thu Dec 06, 2007 2:50 am
How do I create an array of a set amount of elements in PHP.
All I can find is examples of where an array is created and the elements are immediately set.
What I want is something like
i.e. to create an element of 1000 elements, must we always specify this when creating an array or can you have a totally dynamic array?
Thanks.
All I can find is examples of where an array is created and the elements are immediately set.
What I want is something like
Code: Select all
$new_arr = new Array(1000);Thanks.