summaryrefslogtreecommitdiff
path: root/modules/pref-feeds.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2011-06-14 13:43:01 +0400
committerAndrew Dolgov <[email protected]>2011-06-14 13:43:01 +0400
commite3ba4e29216711dc00317d52fd21716166e203dc (patch)
treeb9e2cbd2cc1a54cf7044cbe634b06a2040e82b61 /modules/pref-feeds.php
parent2e2d0802f1ae4bd8cc82ddc53383b3927d4a1064 (diff)
pref-feeds: show subscribed feeds count (closes #338)
Diffstat (limited to 'modules/pref-feeds.php')
-rw-r--r--modules/pref-feeds.php12
1 files changed, 12 insertions, 0 deletions
diff --git a/modules/pref-feeds.php b/modules/pref-feeds.php
index 5a65b0dd5..0a1fed096 100644
--- a/modules/pref-feeds.php
+++ b/modules/pref-feeds.php
@@ -79,8 +79,12 @@
array_push($cat['items'], $feed);
}
+ $cat['param'] = T_sprintf('(%d feeds)', count($cat['items']));
+
if (count($cat['items']) > 0)
array_push($root['items'], $cat);
+
+ $root['param'] += count($cat['items']);
}
/* Uncategorized is a special case */
@@ -112,9 +116,14 @@
array_push($cat['items'], $feed);
}
+ $cat['param'] = T_sprintf('(%d feeds)', count($cat['items']));
+
if (count($cat['items']) > 0)
array_push($root['items'], $cat);
+ $root['param'] += count($cat['items']);
+ $root['param'] = T_sprintf('(%d feeds)', $root['param']);
+
} else {
$feed_result = db_query($link, "SELECT id, title, last_error,
".SUBSTRING_FOR_DATE."(last_updated,1,19) AS last_updated
@@ -135,6 +144,9 @@
array_push($root['items'], $feed);
}
+
+ $root['param'] = T_sprintf('(%d feeds)', count($root['items']));
+
}
$fl = array();