<input name="array[]" type="text">
i used something like this in a series of checkbox's to grab all the
values in an array....i'm not sure if it can be used in this way though,
but give it a go...
-jack
Jason Lotito wrote:
>
> Okay, here is the question, I have a form that will continue to grow in the
> number of elements that it contains. The values are passed into a function,
> and then written out to a file.
>
> Currently, I have 38 seperate values that are being passed into this
> function, making the arguments for the function very long. Now, I know I
> can pass an array into a function, however, I would like to know if there
> was a way to name the elements of the form as in an array, for example:
>
> <input name="array[1]" type="text">
> <input name="array[2]" type="text">
> <input name="array[3]" type="text">
> <input name="array[4]" type="text">
>
> and then, rather than having to pass all 38 seperate arguements into the
> function, I could simply pass the array like this:
>
> function_name($array);
>
> And then simply dissect the array inside the function like normal?
>
> Thanks
>
> Jason Lotito
> www.NewbieNetwork.net
> Where those who can, teach;
> and those who can, learn.
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]