diff options
author | Andrew Dolgov <[email protected]> | 2005-08-25 12:20:50 +0100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2005-08-25 12:20:50 +0100 |
commit | 9cfc649af5e3a397f530475a16a2ae51965e948b (patch) | |
tree | 01bae7fb4b9ae3a80ff0c9de6be969175a9b4e82 /backend.php | |
parent | e695fdc83ef295fd18e9757ff5b12f3d9a8d213c (diff) |
keyboard navigation and cute active headline selection
Diffstat (limited to 'backend.php')
-rw-r--r-- | backend.php | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/backend.php b/backend.php index 0105253dc..bc8524742 100644 --- a/backend.php +++ b/backend.php @@ -109,6 +109,31 @@ $subop = $_GET["subop"]; + if ($subop == "getRelativeId") { + $mode = $_GET["mode"]; + $id = $_GET["id"]; + $feed_id = $_GET["feed"]; + + if ($id != 'false' && $feed_id != 'false') { + + if ($mode == 'next') { + $check_qpart = "updated >= "; + } else { + $idcheck_qpart = "id < '$id'"; + } + + $result = pg_query("SELECT id FROM ttrss_entries WHERE + $check_qpart AND + feed_id = '$feed_id' + ORDER BY updated DESC LIMIT 1"); + + $result_id = pg_fetch_result($result, 0, "id"); + + print "M $mode : P $id -> P $result_id : F $feed_id"; + + } + } + if ($subop == "forceUpdateAllFeeds") { update_all_feeds($link, true); outputFeedList($link); |