<?php
+use Friendica\App;
+
/**
* @file include/ForumManager.php
* @brief ForumManager class with its methods related to forum functionality *
if (!$contacts)
return($forumlist);
- foreach ($contacts as $contact) {
+ foreach($contacts as $contact) {
$forumlist[] = array(
'url' => $contact['url'],
'name' => $contact['name'],
*/
public static function widget($uid,$cid = 0) {
- if (! intval(feature_enabled(local_user(),'forumlist_widget')))
+ if(! intval(feature_enabled(local_user(),'forumlist_widget')))
return;
$o = '';
$id = 0;
- foreach ($contacts as $contact) {
+ foreach($contacts as $contact) {
$selected = (($cid == $contact['id']) ? ' forum-selected' : '');
public static function profile_advanced($uid) {
$profile = intval(feature_enabled($uid,'forumlist_profile'));
- if (! $profile)
+ if(! $profile)
return;
$o = '';
$total_shown = 0;
- foreach ($contacts as $contact) {
+ foreach($contacts as $contact) {
$forumlist .= micropro($contact,false,'forumlist-profile-advanced');
$total_shown ++;
-
- if ($total_shown == $show_total) {
+ if($total_shown == $show_total)
break;
- }
}
- if (count($contacts) > 0) {
+ if(count($contacts) > 0)
$o .= $forumlist;
- }
-
- return $o;
+ return $o;
}
/**