[nycphp-talk] PHP Form handling with mutipart/form-data
The RainMan
rainman at deroo.net
Tue Sep 3 09:21:24 EDT 2002
Phil--
>I know that PHP uses $HTTP_FORM_VARS associative array variable (or $FORM
>too I think I forget),
Actually $HTTP_*_VARS has been deprecated, although still available. The
preferred way is to use $_POST, $_GET, $_REQUEST, as necessary.
>however, can PHP use these variables if the form submitted was of type
>multipart/form-data?
Sure, not a problem. Any time I need to deal with file uploads I use
multipart/form-data, works just the same.
>E.g.
>
><form method=post action=blah.php enctype=multipart/form-data>
>..
><input type=file name=file>
>..
></form>
>
>How would PHP handle a form such as this, where you would be uploading
>files?
Just as it does any other form. For an in depth look on dealing with file
uploads check out http://www.php.net/manual/en/features.file-upload.php
.r
More information about the talk
mailing list