src/Net/FTP/Writer.php
public function changeRights( $fileName, $mode )
	{
		if( !is_int( $mode ) )
			throw new InvalidArgumentException( 'Mode must be an integer, recommended to be given as octal value' );
		$this->connection->checkConnection();
		$result = @ftp_chmod( $this->connection->getResource(), $mode, $fileName );
		if( FALSE === $result )
			throw new RuntimeException( 'Changing rights for "'.$fileName.'" is not possible' );
		return $result;
	}
public function changeRights( $fileName, $mode )
	{
		if( !is_int( $mode ) )
			throw new InvalidArgumentException( 'Mode must be an integer, recommended to be given as octal value' );
		$this->connection->checkConnection();
		$result = @ftp_chmod( $this->connection->getResource(), $mode, $fileName );
		if( FALSE === $result )
			throw new RuntimeException( 'Changing rights for "'.$fileName.'" is not possible' );
		return $result;
	}
public function changeRights ( $ fileName , $ mode ) { if ( ! is_int ( $ mode ) ) throw new InvalidArgumentException ( 'Mode must be an integer, recommended to be given as octal value' ) ; $ this -> connection -> checkConnection ( ) ; $ result = @ ftp_chmod ( $ this -> connection -> getResource ( ) , $ mode , $ fileName ) ; if ( FALSE === $ result ) throw new RuntimeException ( 'Changing rights for "' . $ fileName . '" is not possible' ) ; return $ result ; }
Changes Rights of File or Folders on FTP Server.
@access		public
@param		string		$fileName		Name of file to change rights for
@param		integer		$mode			Mode of rights (i.e. 0755)
@return		integer		Set permissions as integer
@throws		RuntimeException if impossible to change rights
Changes Rights of File or Folders on FTP Server .