Support Joomla!

references:joomla.framework:client:jftp-store

Table of Contents

store

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

This method stores a file on the FTP server. It returns true if successful, false otherwise.

Syntax

boolean store ( $local, $remote )

$local string Path to local file to store on the FTP server
$remote string FTP path to file to create

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->store( 'robots.txt', 'testing/robots.txt' ) ) {
    echo "File stored successfully!";
} else {
    echo "File could not be stored!";
}

might produce:

Result

File stored successfully!
 
references/joomla.framework/client/jftp-store.txt (534 views) · Last modified: 2007/08/15 15:13