aboutsummaryrefslogtreecommitdiffhomepage
path: root/application/Router.php
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2018-07-28 11:07:55 +0200
committerArthurHoaro <arthur@hoa.ro>2018-07-28 11:07:55 +0200
commit83faedadff76c5bdca036f39f13943f63b27e164 (patch)
tree6f44cede16ec6a60f10b9699e211e0818f06d2c8 /application/Router.php
parent1d9eb22a3df85b67fe6652c0876cd7382c2fb525 (diff)
parent658988f3aeba7a5a938783249ccf2765251e5597 (diff)
downloadShaarli-83faedadff76c5bdca036f39f13943f63b27e164.tar.gz
Shaarli-83faedadff76c5bdca036f39f13943f63b27e164.tar.zst
Shaarli-83faedadff76c5bdca036f39f13943f63b27e164.zip
Merge tag 'v0.9.7' into stable
Release v0.9.7
Diffstat (limited to 'application/Router.php')
-rw-r--r--application/Router.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/application/Router.php b/application/Router.php
index caed4a28..4df0387c 100644
--- a/application/Router.php
+++ b/application/Router.php
@@ -13,6 +13,8 @@ class Router
13 13
14 public static $PAGE_TAGCLOUD = 'tagcloud'; 14 public static $PAGE_TAGCLOUD = 'tagcloud';
15 15
16 public static $PAGE_TAGLIST = 'taglist';
17
16 public static $PAGE_DAILY = 'daily'; 18 public static $PAGE_DAILY = 'daily';
17 19
18 public static $PAGE_FEED_ATOM = 'atom'; 20 public static $PAGE_FEED_ATOM = 'atom';
@@ -31,6 +33,8 @@ class Router
31 33
32 public static $PAGE_EDITLINK = 'edit_link'; 34 public static $PAGE_EDITLINK = 'edit_link';
33 35
36 public static $PAGE_DELETELINK = 'delete_link';
37
34 public static $PAGE_EXPORT = 'export'; 38 public static $PAGE_EXPORT = 'export';
35 39
36 public static $PAGE_IMPORT = 'import'; 40 public static $PAGE_IMPORT = 'import';
@@ -43,6 +47,8 @@ class Router
43 47
44 public static $PAGE_SAVE_PLUGINSADMIN = 'save_pluginadmin'; 48 public static $PAGE_SAVE_PLUGINSADMIN = 'save_pluginadmin';
45 49
50 public static $GET_TOKEN = 'token';
51
46 /** 52 /**
47 * Reproducing renderPage() if hell, to avoid regression. 53 * Reproducing renderPage() if hell, to avoid regression.
48 * 54 *
@@ -75,6 +81,10 @@ class Router
75 return self::$PAGE_TAGCLOUD; 81 return self::$PAGE_TAGCLOUD;
76 } 82 }
77 83
84 if (startsWith($query, 'do='. self::$PAGE_TAGLIST)) {
85 return self::$PAGE_TAGLIST;
86 }
87
78 if (startsWith($query, 'do='. self::$PAGE_OPENSEARCH)) { 88 if (startsWith($query, 'do='. self::$PAGE_OPENSEARCH)) {
79 return self::$PAGE_OPENSEARCH; 89 return self::$PAGE_OPENSEARCH;
80 } 90 }
@@ -120,6 +130,10 @@ class Router
120 return self::$PAGE_EDITLINK; 130 return self::$PAGE_EDITLINK;
121 } 131 }
122 132
133 if (isset($get['delete_link'])) {
134 return self::$PAGE_DELETELINK;
135 }
136
123 if (startsWith($query, 'do='. self::$PAGE_EXPORT)) { 137 if (startsWith($query, 'do='. self::$PAGE_EXPORT)) {
124 return self::$PAGE_EXPORT; 138 return self::$PAGE_EXPORT;
125 } 139 }
@@ -136,6 +150,10 @@ class Router
136 return self::$PAGE_SAVE_PLUGINSADMIN; 150 return self::$PAGE_SAVE_PLUGINSADMIN;
137 } 151 }
138 152
153 if (startsWith($query, 'do='. self::$GET_TOKEN)) {
154 return self::$GET_TOKEN;
155 }
156
139 return self::$PAGE_LINKLIST; 157 return self::$PAGE_LINKLIST;
140 } 158 }
141} 159}