From 192df273ccd2b9f527b44622379ebb6142fcc611 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 14 Nov 2016 12:01:16 +0100 Subject: show wiki controls only to owner and whitespace fixes --- include/widgets.php | 2 +- view/tpl/wikilist.tpl | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/include/widgets.php b/include/widgets.php index ff97b8bd5..071622387 100644 --- a/include/widgets.php +++ b/include/widgets.php @@ -917,7 +917,7 @@ function widget_wiki_list($arr) { '$channel' => $channel['channel_address'], '$wikis' => $wikis['wikis'], // If the observer is the local channel owner, show the wiki controls - '$showControls' => ((local_channel() === intval($channel['channel_id'])) ? true : false) + '$owner' => ((local_channel() === intval($channel['channel_id'])) ? true : false) )); } return ''; diff --git a/view/tpl/wikilist.tpl b/view/tpl/wikilist.tpl index 7cf04d35e..0828d78fa 100644 --- a/view/tpl/wikilist.tpl +++ b/view/tpl/wikilist.tpl @@ -2,11 +2,13 @@

{{$header}}

{{foreach $wikis as $wiki}} -
- {{$wiki.title}} - - -
+
+ {{$wiki.title}} + {{if $owner}} + + + {{/if}} +
{{/foreach}}
-- cgit v1.2.3