# HG changeset patch # User nanaya # Date 1440418436 -32400 # Node ID 5a4c9efd99fc9d4864cc2a4343e63f9d6dee4ef7 # Parent 4e85d97e41b63d0b0e3b161373db806e635db309 No more globals. diff -r 4e85d97e41b6 -r 5a4c9efd99fc index.php --- a/index.php Fri Aug 07 21:01:49 2015 +0900 +++ b/index.php Mon Aug 24 21:13:56 2015 +0900 @@ -67,9 +67,7 @@ } // END UTILITY - function tree_link() { - global $uri; - + function tree_link($uri) { $uri_array = explode("/", trim($uri, "/")); $tree_path = "/"; @@ -85,16 +83,13 @@ return $tree_link; } - function up_link() { - global $uri; + function up_link($uri) { if ($uri !== "/") { return "" . link_to(dirname($uri) . "/", "[up]") . ""; } } - function file_rows($files, $is_dir) { - global $dir, $uri; - + function file_rows($dir, $files, $is_dir) { $file_rows = ""; $file_suffix = ""; $list_file_prefix = hidden_data("", $is_dir); @@ -207,7 +202,7 @@ -

Index of

+

Index of

@@ -218,11 +213,11 @@ Size Date - + - - + +