diff options
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 13 |
1 files changed, 10 insertions, 3 deletions
@@ -1320,10 +1320,17 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history) | |||
1320 | die('Wrong token.'); | 1320 | die('Wrong token.'); |
1321 | } | 1321 | } |
1322 | 1322 | ||
1323 | if (strpos($_GET['lf_linkdate'], ' ') !== false) { | 1323 | $ids = trim($_GET['lf_linkdate']); |
1324 | $ids = array_values(array_filter(preg_split('/\s+/', escape($_GET['lf_linkdate'])))); | 1324 | if (strpos($ids, ' ') !== false) { |
1325 | // multiple, space-separated ids provided | ||
1326 | $ids = array_values(array_filter(preg_split('/\s+/', escape($ids)))); | ||
1325 | } else { | 1327 | } else { |
1326 | $ids = [$_GET['lf_linkdate']]; | 1328 | // only a single id provided |
1329 | $ids = [$ids]; | ||
1330 | } | ||
1331 | // assert at least one id is given | ||
1332 | if(!count($ids)){ | ||
1333 | die('no id provided'); | ||
1327 | } | 1334 | } |
1328 | foreach ($ids as $id) { | 1335 | foreach ($ids as $id) { |
1329 | $id = (int) escape($id); | 1336 | $id = (int) escape($id); |