summaryrefslogtreecommitdiff
path: root/www/index.php
diff options
context:
space:
mode:
authorroot2014-03-22 02:14:04 +0100
committerroot2014-03-22 02:14:04 +0100
commitf1840d40760abb9869bd218ca510eceb94f86478 (patch)
tree5e7afdd68c2e639bfa89c91fa3da07749b4fc093 /www/index.php
parent296d8a14511739a15327ffe30c0895cd3490e940 (diff)
downloadfiles.iamfabulous.de-f1840d40760abb9869bd218ca510eceb94f86478.tar.gz
Differences between folder_is_empty and file_not_found. TODO: Extra design for empty folder.
Diffstat (limited to 'www/index.php')
-rwxr-xr-xwww/index.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/www/index.php b/www/index.php
index 1bfb993..ad7eb7d 100755
--- a/www/index.php
+++ b/www/index.php
@@ -94,7 +94,15 @@ if(empty($_GET)){
if(rewrite($db)){
if(!check_if_file($db, $_GET["name"], $_GET["folder"])){
$content = collect_content($db, $_GET["name"], $_GET["folder"]);
- print_browser($content);
+ if($content == FILE_NOT_FOUND){
+ $content = get_path_to_wrong_folder($db, $_GET["name"], $_GET["folder"]);
+ print_wrong_folder($content);
+ } elseif ($content == EMPTY_FOLDER){
+ print_browser($content);
+ //TODO: echo "print: folder_is_empty"; exit;
+ } else {
+ print_browser($content);
+ }
} else {
start_file_download($_GET["name"], $_GET["folder"]);
}