* @return string|false The location of the remote path, false on failure.
*/
public function find_folder( $folder ) {
-
if ( isset( $this->cache[ $folder ] ) )
return $this->cache[ $folder ];
* @return string The *nix-style representation of permissions.
*/
public function gethchmod( $file ){
- $perms = $this->getchmod($file);
+ $perms = intval( $this->getchmod( $file ), 8 );
if (($perms & 0xC000) == 0xC000) // Socket
$info = 's';
elseif (($perms & 0xA000) == 0xA000) // Symbolic Link
return $info;
}
+ /**
+ * Gets the permissions of the specified file or filepath in their octal format
+ *
+ * @since 2.5.0
+ * @param string $file
+ * @return string the last 3 characters of the octal number
+ */
+ public function getchmod( $file ) {
+ return '777';
+ }
+
/**
* Convert *nix-style file permissions to a octal number.
*
* @since 2.5.0
* @abstract
* @param string $dir The new current directory.
- * @return bool Returns true on success or false on failure.
+ * @return bool|string
*/
public function chdir( $dir ) {
return false;
* @param string $file Path to the file.
* @param mixed $group A group name or number.
* @param bool $recursive Optional. If set True changes file group recursively. Defaults to False.
- * @return bool Returns true on success or false on failure.
+ * @return bool|string
*/
public function chgrp( $file, $group, $recursive = false ) {
return false;
* @param string $file Path to the file.
* @param int $mode Optional. The permissions as octal number, usually 0644 for files, 0755 for dirs.
* @param bool $recursive Optional. If set True changes file group recursively. Defaults to False.
- * @return bool Returns true on success or false on failure.
+ * @return bool|string
*/
public function chmod( $file, $mode = false, $recursive = false ) {
return false;