Curriculum
Course: PHP Basic
Login

Curriculum

PHP Basic

PHP Install

0/1

PHP Casting

0/1

PHP Constants

0/1

PHP Magic Constants

0/1

PHP Operators

0/1

PHP Reference

0/276
Text lesson

move_uploaded_file()

Definition and Usage

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.

Syntax

move_uploaded_file(filedest)

Parameter Values

 

Parameter

Description

file

Essential. gives the uploaded file’s filename.

dest

Essential. identifies the file’s new location.

Technical Details

Return Value:

FALSE when it fails, TRUE when it succeeds

PHP Version:

4.0.3+