Javatpoint Logo
Javatpoint Logo

PHP ftp_cdup() Function

The ftp_cdup() function is used to change the current directory to the parent directory. This function was introduced in PHP 4.

Syntax:

Parameter Description Is compulsory
ftp_stream The link identifier of the FTP connection. compulsory

Returns

The ftp_cdup( ) function returns TRUE on success or FALSE on failure.

Example 1

Explanation

In the above example, by using the ftp_cdup() function we change the current directory to the parent directory.

Example 2

Explanation

In the above example, by using ftp_chdir( ) function we change the directory and after that by using ftp_cdup( ) function we change the directory to the parent.

Example 3

Explanation

In the above example, by using ftp_cdup( ) function we change the directory to parent directory.


Next TopicPHP FTP





Youtube For Videos Join Our Youtube Channel: Join Now

Feedback


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA