示例#1
0
 /**
  * Create directory on sftp location
  * @param string $directory Remote directory path
  * @return bool true if directory creation success
  * @throws CException if directory creation fails
  */
 function createDirectory($directory)
 {
     if ($this->objSftp->mkdir($directory)) {
         return true;
     } else {
         throw new CException(Yii::t('XSFtp.sftp', 'Directory creation failed.'));
     }
 }