diff options
author | Simon L'nu <simon.lnu@gmail.com> | 2012-04-14 15:12:39 -0400 |
---|---|---|
committer | Simon L'nu <simon.lnu@gmail.com> | 2012-04-14 15:12:39 -0400 |
commit | 1dd22be4d2fe997d9bde552f8d8a25ba12c67e7e (patch) | |
tree | 32486e253628ab64fa466f34dfc0703d9ce8644c /include | |
parent | 16f729912a00cc92d0473f3d326080531a2fb393 (diff) | |
parent | 6591b292a1e22e3eaec41af0a61a6911e9847098 (diff) | |
download | volse-hubzilla-1dd22be4d2fe997d9bde552f8d8a25ba12c67e7e.tar.gz volse-hubzilla-1dd22be4d2fe997d9bde552f8d8a25ba12c67e7e.tar.bz2 volse-hubzilla-1dd22be4d2fe997d9bde552f8d8a25ba12c67e7e.zip |
Merge branch 'master', remote-tracking branch 'remotes/upstream/master'
* remotes/upstream/master:
bogus empty list element in dfrn_request page when emailnet not enabled
zrl on random profile
zrl hook
bug #372 - category feeds
pass zrl's to/through global directory
* master:
Diffstat (limited to 'include')
-rw-r--r-- | include/items.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/items.php b/include/items.php index 05c0d5016..85df340d3 100644 --- a/include/items.php +++ b/include/items.php @@ -19,9 +19,15 @@ function get_feed_for(&$a, $dfrn_id, $owner_nick, $last_update, $direction = 0) $converse = true; if($a->argv[$x] == 'starred') $starred = true; + if($a->argv[$x] === 'category' && $a->argc > ($x + 1) && strlen($a->argv[$x+1])) + $category = $a->argv[$x+1]; } + + } + + // default permissions - anonymous user $sql_extra = " AND `allow_cid` = '' AND `allow_gid` = '' AND `deny_cid` = '' AND `deny_gid` = '' "; @@ -101,6 +107,10 @@ function get_feed_for(&$a, $dfrn_id, $owner_nick, $last_update, $direction = 0) if(! strlen($last_update)) $last_update = 'now -30 days'; + if(x($category)) { + $sql_extra .= file_tag_file_query('item',$category,'category'); + } + if($public_feed) { if(! $converse) $sql_extra .= " AND `contact`.`self` = 1 "; |