| @@ 802-814 (lines=13) @@ | ||
| 799 | return is_writable($location); |
|
| 800 | } |
|
| 801 | ||
| 802 | function rmdir($dir) { |
|
| 803 | foreach ( scandir($dir) as $file ) { |
|
| 804 | if ( !in_array($file, array('.', '..')) ) { |
|
| 805 | if ( is_dir($dir . '/' . $file) ) { |
|
| 806 | $this->rmdir($dir . '/' . $file); |
|
| 807 | } else { |
|
| 808 | unlink($dir . '/' . $file); |
|
| 809 | } |
|
| 810 | } |
|
| 811 | } |
|
| 812 | ||
| 813 | return rmdir($dir); |
|
| 814 | } |
|
| 815 | ||
| 816 | function displayPath($pathname) { |
|
| 817 | if ( DIRECTORY_SEPARATOR == '/' ) { |
|
| @@ 854-866 (lines=13) @@ | ||
| 851 | return is_writable($location); |
|
| 852 | } |
|
| 853 | ||
| 854 | function rmdir($dir) { |
|
| 855 | foreach ( scandir($dir) as $file ) { |
|
| 856 | if ( !in_array($file, array('.', '..')) ) { |
|
| 857 | if ( is_dir($dir . '/' . $file) ) { |
|
| 858 | $this->rmdir($dir . '/' . $file); |
|
| 859 | } else { |
|
| 860 | unlink($dir . '/' . $file); |
|
| 861 | } |
|
| 862 | } |
|
| 863 | } |
|
| 864 | ||
| 865 | return rmdir($dir); |
|
| 866 | } |
|
| 867 | ||
| 868 | function displayPath($pathname) { |
|
| 869 | if ( DIRECTORY_SEPARATOR == '/' ) { |
|