use '?random=jpg' to get an URL of a random file

pull/31/head
qkqpttgf 2020-03-09 19:02:05 +08:00 committed by GitHub
parent 46714bff6b
commit 57ead42c49
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -617,7 +617,7 @@ function main($path)
$files = list_files($path);
//echo json_encode(array_keys($files['children']), JSON_PRETTY_PRINT);
if ($_GET['random']!=='') {
if (isset($_GET['random'])&&$_GET['random']!=='') {
if ($_SERVER['ishidden']<4) {
$tmp = [];
foreach (array_keys($files['children']) as $filename) {