Current Location: Home> Function Categories> ftp_pwd

ftp_pwd

Returns the current directory name.
Name:ftp_pwd
Category:Uncategorized
Programming Language:php
One-line Description:Returns the current directory name.

Definition and usage

The ftp_pwd() function returns the current directory name.

Example

 <?php
$conn = ftp_connect ( "ftp.testftp.com" ) or die ( "Could not connect" ) ;
ftp_login ( $conn , "admin" , "ert456" ) ;

// Output the current directory
echo ftp_pwd ( $conn ) . "<br />" ;

// Change the directory to images
ftp_chdir ( $conn , "images" ) ;

// Output the current directory
echo ftp_pwd ( $conn ) ;

ftp_close ( $conn ) ;
?>

grammar

 ftp_pwd ( ftp_connection )
parameter describe
ftp_connection Required. Specifies the FTP connection to be used (the identifier of the FTP connection).
Similar Functions
Popular Articles