diff --git a/NEWS b/NEWS index 2922fb8a1..8894e4780 100644 --- a/NEWS +++ b/NEWS @@ -11,6 +11,7 @@ v1.1 (Dec xy, 2005) * Per-feed content filters * Support for user stylesheets * Feed categories + * "Mark as read" for tags v1.0.7 (Nov 14, 2005) diff --git a/backend.php b/backend.php index af49cf2a1..df4abeff5 100644 --- a/backend.php +++ b/backend.php @@ -677,7 +677,19 @@ } } } else { // tag - // FIXME, implement catchup for tags + db_query($link, "BEGIN"); + + $tag_name = db_escape_string($feed); + + $result = db_query($link, "SELECT post_int_id FROM ttrss_tags + WHERE tag_name = '$tag_name' AND owner_uid = " . $_SESSION["uid"]); + + while ($line = db_fetch_assoc($result)) { + db_query($link, "UPDATE ttrss_user_entries SET + unread = false, last_read = NOW() + WHERE int_id = " . $line["post_int_id"]); + } + db_query($link, "COMMIT"); } } diff --git a/feedlist.js b/feedlist.js index 93b598146..133125635 100644 --- a/feedlist.js +++ b/feedlist.js @@ -90,12 +90,12 @@ function viewfeed(feed, skip, subop, doc) { disableContainerChildren("headlinesToolbar", false, doc); - var btnMarkAsRead = doc.getElementById("btnMarkFeedAsRead"); +/* var btnMarkAsRead = doc.getElementById("btnMarkFeedAsRead"); if (btnMarkAsRead && !isNumeric(feed)) { btnMarkAsRead.disabled = true; btnMarkAsRead.className = "disabledButton"; - } + } */ // notify("");