An uploaded file is moved to a new location using the move_uploaded_file() function.
Note: Only files uploaded using PHP’s HTTP POST upload mechanism are compatible with this function.
Note: The target file will be rewritten if it already exists.
move_uploaded_file(file, dest) |
Parameter |
Description |
file |
Essential. gives the uploaded file’s filename. |
dest |
Essential. identifies the file’s new location. |
Return Value: |
FALSE when it fails, TRUE when it succeeds |
PHP Version: |
4.0.3+ |