summaryrefslogtreecommitdiff
path: root/backend.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2006-08-20 14:40:03 +0100
committerAndrew Dolgov <[email protected]>2006-08-20 14:40:03 +0100
commit0e317f9d872f538fbf13f81e8a72272ab2c92e84 (patch)
tree9f03652fb0a24d57bb154b4a7641e2438995925e /backend.php
parent7e3634d91891d5ab85f8d0b021bc296d728c92c7 (diff)
sortable filter list
Diffstat (limited to 'backend.php')
-rw-r--r--backend.php16
1 files changed, 11 insertions, 5 deletions
diff --git a/backend.php b/backend.php
index 9b38303d5..d9a4fe72d 100644
--- a/backend.php
+++ b/backend.php
@@ -2101,6 +2101,12 @@
if ($quiet) return;
+ $sort = db_escape_string($_GET["sort"]);
+
+ if (!$sort || $sort == "undefined") {
+ $sort = "reg_exp";
+ }
+
// print "<div id=\"infoBoxShadow\"><div id=\"infoBox\">PLACEHOLDER</div></div>";
$result = db_query($link, "SELECT id,description
@@ -2133,7 +2139,7 @@
filter_type = ttrss_filter_types.id AND
ttrss_filter_actions.id = action_id AND
ttrss_filters.owner_uid = ".$_SESSION["uid"]."
- ORDER by reg_exp");
+ ORDER by $sort");
if (db_num_rows($result) != 0) {
@@ -2150,10 +2156,10 @@
print "<tr class=\"title\">
<td align='center' width=\"5%\">&nbsp;</td>
- <td width=\"20%\">Filter expression</td>
- <td width=\"20%\">Feed</td>
- <td width=\"15%\">Match</td>
- <td width=\"15%\">Action</td>";
+ <td width=\"20%\"><a href=\"javascript:updateFilterList('reg_exp')\">Filter expression</a></td>
+ <td width=\"20%\"><a href=\"javascript:updateFilterList('feed_title')\">Feed</a></td>
+ <td width=\"15%\"><a href=\"javascript:updateFilterList('filter_type')\">Match</a></td>
+ <td width=\"15%\"><a href=\"javascript:updateFilterList('action_description')\">Action</a></td>";
$lnum = 0;