API16:JFTP/mkdir
From Joomla! Documentation
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.
Contents |
Description
Method to create a directory on the FTP server
[<! removed edit link to red link >]
<! removed transcluded page call, red link never existed >
Syntax
mkdir($path)
| Parameter Name | Default Value | Description |
|---|---|---|
| $path | $path Directory to create |
Returns
boolean True if successful
Defined in
libraries/joomla/client/ftp.php
Importing
jimport( 'joomla.client.ftp' );
Source Body
function mkdir($path) { // If native FTP support is enabled lets use it... if (FTP_NATIVE) { if (@ftp_mkdir($this->_conn, $path) === false) { JError::raiseWarning('35', 'JFTP::mkdir: Bad response'); return false; } return true; } // Send change directory command and verify success if (!$this->_putCmd('MKD '.$path, 257)) { JError::raiseWarning('35', 'JFTP::mkdir: Bad response', 'Server response: '.$this->_response.' [Expected: 257] Path sent: '.$path); return false; } return true; }
[<! removed edit link to red link >] <! removed transcluded page call, red link never existed >
Examples
<CodeExamplesForm />
