Support Joomla!

references:joomla.framework:client:jftp-create

Table of Contents

create

API Package Subpackage Class Method Reference Last reviewed Doc status
API Home Package Joomla.Framework Subpackage Client Class JFTP Method create Reference create() Never Work in Progress

Method to create an empty file on the FTP server.

Syntax

boolean create ( $path )

$path string is a string containing the path to the local file to store on the FTP server.

Examples

Example

jimport( 'joomla.connector.ftp' );

$ftp = new JFTP( array( 'type' => FTP_BINARY ) );
$ftp->connect( '127.0.0.1' );
$ftp->login( 'testuser', 'testpass' );

if ($ftp->create( 'robots.txt' ) ) {
    echo "Create successful!";
} else {
    echo "Create failed!";
}

might produce:

Result

Create successful!
 
references/joomla.framework/client/jftp-create.txt (592 views) · Last modified: 2007/08/15 15:13