diff options
author | filip <filip.komar@gmail.com> | 2017-08-10 00:14:28 +0200 |
---|---|---|
committer | filip <filip.komar@gmail.com> | 2017-08-10 00:14:28 +0200 |
commit | 9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09 (patch) | |
tree | c3b09fa3f38ac726c83989105d0ee155be72f2f1 /test | |
parent | c7a042e3784abb892eed23bf34c9649beb51c37e (diff) | |
download | www-9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09.tar www-9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09.tar.gz www-9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09.tar.bz2 www-9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09.tar.xz www-9cbce860a02925bfc6e8e151b5a7c2ce9c63ce09.zip |
testing server side fs 3
Diffstat (limited to 'test')
-rw-r--r-- | test/lang.php | 24 |
1 files changed, 18 insertions, 6 deletions
diff --git a/test/lang.php b/test/lang.php index f41c50955..33fc2e093 100644 --- a/test/lang.php +++ b/test/lang.php @@ -10,14 +10,14 @@ echo "Relocate `community` with `en` as a default: ", relocate($langs, 'communit echo "\nTests:\n"; -$test_dir = '../sv/'; +$test_dir = '../sv/map/index.php'; $lstat = ''; if (file_exists($test_dir)) { echo "The file $test_dir exists\n"; $lstat = lstat($test_dir); // $linkinfo = linkinfo($test_dir); - $readlink = readlink($test_dir . 'map'); +// $readlink = readlink($test_dir); } else { echo "The file $test_dir does not exist\n"; } @@ -28,6 +28,12 @@ if (is_dir($test_dir)) { echo "The $test_dir is not a dir.\n"; } +if (is_file($test_dir)) { + echo "The $test_dir is a file\n"; +} else { + echo "The $test_dir is not a file.\n"; +} + if (is_readable($test_dir)) { echo "The file $test_dir is readable\n"; } else { @@ -35,17 +41,17 @@ if (is_readable($test_dir)) { } var_dump($lstat); -var_dump($readlink); +// var_dump($readlink); -$test_dir = '../sl/'; +$test_dir = '../sl/map/index.php'; $lstat2 = ''; if (file_exists($test_dir)) { echo "The file $test_dir exists\n"; $lstat2 = lstat($test_dir); // $linkinfo = linkinfo($test_dir); - $readlink = readlink($test_dir . 'map'); +// $readlink = readlink($test_dir); } else { echo "The file $test_dir does not exist\n"; } @@ -56,6 +62,12 @@ if (is_dir($test_dir)) { echo "The $test_dir is not a dir.\n"; } +if (is_file($test_dir)) { + echo "The $test_dir is a file\n"; +} else { + echo "The $test_dir is not a file.\n"; +} + if (is_readable($test_dir)) { echo "The file $test_dir is readable\n"; } else { @@ -63,7 +75,7 @@ if (is_readable($test_dir)) { } var_dump($lstat2); -var_dump($readlink); +// var_dump($readlink); $diff = array_diff($lstat, $lstat2); var_dump($diff); |