note 68575 deleted from function.ftp-nlist by bjori
| From: | bjori@php.net | Date: | Wed, 02 Aug 2006 13:22:53 +0000 |
| Subject: | note 68575 deleted from function.ftp-nlist by bjori | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-115471@lists.php.net to get a copy of this message | ||
Note Submitter:
Reason: useless
----
To look if a dir is isset you can try to change to the path, if it isn't a dir, ftp_chdir will
return false
//Looks if a directory ($dir) is isset
//returns true or false
function ftp_is_dir( $conn_id, $dir )
{
if( @ftp_chdir( $conn_id, $dir ) ) {
ftp_chdir( $conn_id, '/../' );
return true;
} else {
return false;
}
}