Re: returning the index number
| From: | Robert Cummings | Date: | Tue, 05 Jun 2007 15:43:49 +0000 |
| Subject: | Re: returning the index number | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-256102@lists.php.net to get a copy of this message | ||
On Tue, 2007-06-05 at 16:39 +0100, blueboy wrote:
> I have an array of files to be uploaded
>
> <td><input name="userfile[]" type="file"></td>
> </tr>
> <tr>
> <td> 2.</td>
> <td><input name="userfile[]" type="file"></td>
> </tr>
> <tr>
> <td>3.</td>
> <td><input name="userfile[]" type="file">
>
>
> I can get the name
>
$i = 0;
> foreach ($_FILES['userfile']['name'] as $value) {
>
> echo $value
$i++;
> }
>
> but I want the index position, any ideas?
See additions above.
Cheers,
Rob.
--
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com
|
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting |
| a powerful, scalable system for accessing system services |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for |
| creating re-usable components quickly and easily. |
`------------------------------------------------------------'