Just to answer my own question, but for reference for anyone else who has
this problem, I made a simple error (not very experienced with PHP). Anyway,
turns out that 'object$objectNumber' is different than 'object'$objectNumber
and also different that just $objectNumber. As most of you know, putting ' '
around a variable makes PHP print it out exactly like that (ie.
'$objectNumber' = $objectNumber in PHP) whereas I just wanted the variable
properties to actually be put into the $_FILES function (or whatever it is).
I couldn't figure out how to put 'object'$objectNumber together so I just
changed it to simply $objectNumber, so it now works.

This is what the code is now:

     $file = $_FILES{$objectNumber};
     $fileName = $file['name'];
     $filetmp = $file['tmp_name'];

... and everything works.

Dimitri Marshall

"Dimitri Marshall" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hi there,
> This is what I'm trying to do:
>
> $pic = $_FILES['object$objectNumber'];
> $picName = $pic['name'];
> $pictmp = $pic['tmp_name'];
>
> $objectNumber is being defined, but for some reason this code won't work.
> Can someone tell me why and also what I can do to make it work?
>
> Thanks in advance,
> Dimitri Marshall

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

Reply via email to