references:joomla.framework:client:jftp-writewrite
This method writes the contents of a buffer to a file on the FTP server. This method returns true if successful, false otherwise. Syntaxboolean write ( $remote, $buffer, $mode )
ExamplesExample jimport( 'joomla.connector.ftp' ); $ftp = new JFTP( array( 'type' => FTP_BINARY ) ); $ftp->connect( '127.0.0.1' ); $ftp->login( 'testuser', 'testpass' ); $buffer = "Joomla! and away! The best selling CMS in its class!"; if ($ftp->write( 'testing/joomla.txt', $buffer ) ) { echo "File written successfully!"; } else { echo "File could not be written!"; } might produce: Result File written successfully!
|


