From 28f26524609338316cc6e51c743058e6e8c7b12b Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Fri, 8 Jun 2018 12:50:49 +0200 Subject: Add a page to update all thumbnails through AJAX requests in both templates --- application/Router.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'application/Router.php') diff --git a/application/Router.php b/application/Router.php index 4df0387c..bf86b884 100644 --- a/application/Router.php +++ b/application/Router.php @@ -7,6 +7,8 @@ */ class Router { + public static $AJAX_THUMB_UPDATE = 'ajax_thumb_update'; + public static $PAGE_LOGIN = 'login'; public static $PAGE_PICWALL = 'picwall'; @@ -47,6 +49,8 @@ class Router public static $PAGE_SAVE_PLUGINSADMIN = 'save_pluginadmin'; + public static $PAGE_THUMBS_UPDATE = 'thumbs_update'; + public static $GET_TOKEN = 'token'; /** @@ -101,6 +105,14 @@ class Router return self::$PAGE_FEED_RSS; } + if (startsWith($query, 'do='. self::$PAGE_THUMBS_UPDATE)) { + return self::$PAGE_THUMBS_UPDATE; + } + + if (startsWith($query, 'do='. self::$AJAX_THUMB_UPDATE)) { + return self::$AJAX_THUMB_UPDATE; + } + // At this point, only loggedin pages. if (!$loggedIn) { return self::$PAGE_LINKLIST; -- cgit v1.2.3 From 4154c25b5f2f8044a37d7f84e04173bb54f2375b Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Tue, 22 May 2018 22:44:38 +0200 Subject: Add a button to set links as sticky Meaning that they always appear on top of all links Fixes #186 --- application/Router.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'application/Router.php') diff --git a/application/Router.php b/application/Router.php index bf86b884..beb3165b 100644 --- a/application/Router.php +++ b/application/Router.php @@ -37,6 +37,8 @@ class Router public static $PAGE_DELETELINK = 'delete_link'; + public static $PAGE_PINLINK = 'pin'; + public static $PAGE_EXPORT = 'export'; public static $PAGE_IMPORT = 'import'; @@ -146,6 +148,10 @@ class Router return self::$PAGE_DELETELINK; } + if (startsWith($query, 'do='. self::$PAGE_PINLINK)) { + return self::$PAGE_PINLINK; + } + if (startsWith($query, 'do='. self::$PAGE_EXPORT)) { return self::$PAGE_EXPORT; } -- cgit v1.2.3