1
0
Fork 0

Merge pull request #3896 from tobiasd/20171110-community

adding a global community disclaimer
This commit is contained in:
Hypolite Petovan 2017-11-10 16:17:38 -05:00 committed by GitHub
commit 6b23548a2b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 4 deletions

View file

@ -87,6 +87,7 @@ Example: To set the directory value please add this line to your .htconfig.php:
* **remove_multiplicated_lines** (Boolean) - If enabled, multiple linefeeds in items are stripped to a single one. * **remove_multiplicated_lines** (Boolean) - If enabled, multiple linefeeds in items are stripped to a single one.
* **show_unsupported_addons** (Boolean) - Show all addons including the unsupported ones. * **show_unsupported_addons** (Boolean) - Show all addons including the unsupported ones.
* **show_unsupported_themes** (Boolean) - Show all themes including the unsupported ones. * **show_unsupported_themes** (Boolean) - Show all themes including the unsupported ones.
* **show_global_community_hint** (Boolean) - When the global community page is enabled, use this option to display a hint above the stream, that this is a collection of all public top-level postings that arrive on your node.
* **throttle_limit_day** - Maximum number of posts that a user can send per day with the API. * **throttle_limit_day** - Maximum number of posts that a user can send per day with the API.
* **throttle_limit_week** - Maximum number of posts that a user can send per week with the API. * **throttle_limit_week** - Maximum number of posts that a user can send per week with the API.
* **throttle_limit_month** - Maximum number of posts that a user can send per month with the API. * **throttle_limit_month** - Maximum number of posts that a user can send per month with the API.

View file

@ -28,8 +28,6 @@ function community_content(App $a, $update = 0) {
require_once('include/security.php'); require_once('include/security.php');
require_once('include/conversation.php'); require_once('include/conversation.php');
$o .= '<h3>' . t('Community') . '</h3>';
if (! $update) { if (! $update) {
nav_set_selected('community'); nav_set_selected('community');
} }
@ -85,7 +83,13 @@ function community_content(App $a, $update = 0) {
$o .= alt_pager($a, count($r)); $o .= alt_pager($a, count($r));
return $o; $t = get_markup_template("community.tpl");
return replace_macros($t, array(
'$content' => $o,
'$header' => t("Community"),
'$show_global_community_hint' => (Config::get('system', 'community_page_style') == CP_GLOBAL_COMMUNITY && Config::get('system', 'show_global_community_hint')),
'$global_community_hint' => t("This community stream shows all public posts received by this node. They may not reflect the opinions of this nodes users.")
));
} }
function community_getitems($start, $itemspage) { function community_getitems($start, $itemspage) {

View file

@ -0,0 +1,7 @@
<h3>{{$header}}</h3>
{{if $show_global_community_hint}}
<p class="hint">{{$global_community_hint}}</p>
{{/if}}
{{$content}}