diff options
author | Alexandre Hannud Abdo <abdo@member.fsf.org> | 2014-03-29 23:20:43 -0300 |
---|---|---|
committer | Alexandre Hannud Abdo <abdo@member.fsf.org> | 2014-03-30 00:03:12 -0300 |
commit | fedd19ec95bfe963ab19d9e55f184b8ffe9f0da0 (patch) | |
tree | b3c6262e6d188b7b7a538b5b19be3b0c3aeb96c0 /include | |
parent | 7ed177c7cde9e987c18d3f0c0b5b3fc6e371c814 (diff) | |
download | volse-hubzilla-fedd19ec95bfe963ab19d9e55f184b8ffe9f0da0.tar.gz volse-hubzilla-fedd19ec95bfe963ab19d9e55f184b8ffe9f0da0.tar.bz2 volse-hubzilla-fedd19ec95bfe963ab19d9e55f184b8ffe9f0da0.zip |
Let the site admin choose whether to display the Discover tab.
Diffstat (limited to 'include')
-rw-r--r-- | include/conversation.php | 21 | ||||
-rw-r--r-- | include/poller.php | 3 |
2 files changed, 13 insertions, 11 deletions
diff --git a/include/conversation.php b/include/conversation.php index ac1b4e456..342392398 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -1382,14 +1382,17 @@ function network_tabs() { $cmd = $a->cmd; // tabs - $tabs = array( - array( - 'label' => t('Discover'), - 'url'=>$a->get_baseurl(true) . '/' . $cmd . '?f=&fh=1' . ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '') . ((x($_GET,'gid')) ? '&gid=' . $_GET['gid'] : ''), - 'sel'=> $public_active, - 'title'=> t('Imported public streams'), - ), + $tabs = array(); + + if(get_config('system','discover_tab')) + $tabs[] = array( + 'label' => t('Discover'), + 'url'=>$a->get_baseurl(true) . '/' . $cmd . '?f=&fh=1' . ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '') . ((x($_GET,'gid')) ? '&gid=' . $_GET['gid'] : ''), + 'sel'=> $public_active, + 'title'=> t('Imported public streams'), + ); + array_push($tabs, array( 'label' => t('Commented Order'), 'url'=>$a->get_baseurl(true) . '/' . $cmd . '?f=&order=comment' . ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '') . ((x($_GET,'gid')) ? '&gid=' . $_GET['gid'] : ''), @@ -1402,7 +1405,6 @@ function network_tabs() { 'sel'=>$postord_active, 'title' => t('Sort by Post Date'), ), - array( 'label' => t('Personal'), 'url' => $a->get_baseurl(true) . '/' . $cmd . '?f=' . ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '') . '&conv=1', @@ -1414,8 +1416,7 @@ function network_tabs() { 'url' => $a->get_baseurl(true) . '/' . $cmd . '?f=' . ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '') . '&new=1' . ((x($_GET,'gid')) ? '&gid=' . $_GET['gid'] : ''), 'sel' => $new_active, 'title' => t('Activity Stream - by date'), - ), - + ) ); if(feature_enabled(local_user(),'star_posts')) diff --git a/include/poller.php b/include/poller.php index 19037ef17..0eb161862 100644 --- a/include/poller.php +++ b/include/poller.php @@ -169,7 +169,8 @@ function poller_run($argv, $argc){ // pull in some public posts - proc_run('php','include/externals.php'); + if(get_config('system','discover_tab')) + proc_run('php','include/externals.php'); $manual_id = 0; |