diff --git a/include/forum.php b/include/Forum.php similarity index 92% rename from include/forum.php rename to include/Forum.php index 290f0134a..847affa87 100644 --- a/include/forum.php +++ b/include/Forum.php @@ -8,7 +8,7 @@ /** * @brief This class handles functions related to the forum functionality */ -class forum { +class Forum { /** * @brief Function to list all forums a user is connected with @@ -27,7 +27,7 @@ class forum { * 'id' => number of the key from the array * 'micro' => contact photo in format micro */ - public static function get_forumlist($uid, $showhidden = true, $lastitem, $showprivate = false) { + public static function get_list($uid, $showhidden = true, $lastitem, $showprivate = false) { $forumlist = array(); @@ -72,7 +72,7 @@ class forum { * The contact id which is used to mark a forum as "selected" * @return string */ - public static function widget_forumlist($uid,$cid = 0) { + public static function widget($uid,$cid = 0) { if(! intval(feature_enabled(local_user(),'forumlist_widget'))) return; @@ -82,7 +82,7 @@ class forum { //sort by last updated item $lastitem = true; - $contacts = self::get_forumlist($uid,true,$lastitem, true); + $contacts = self::get_list($uid,true,$lastitem, true); $total = count($contacts); $visible_forums = 10; @@ -131,7 +131,7 @@ class forum { * @return string * */ - public static function forumlist_profile_advanced($uid) { + public static function profile_advanced($uid) { $profile = intval(feature_enabled($uid,'forumlist_profile')); if(! $profile) @@ -145,7 +145,7 @@ class forum { //don't sort by last updated item $lastitem = false; - $contacts = self::get_forumlist($uid,false,$lastitem,false); + $contacts = self::get_list($uid,false,$lastitem,false); $total_shown = 0; diff --git a/include/identity.php b/include/identity.php index 87c91e6dc..a6932f091 100644 --- a/include/identity.php +++ b/include/identity.php @@ -3,7 +3,7 @@ * @file include/identity.php */ -require_once('include/forum.php'); +require_once('include/Forum.php'); require_once('include/bbcode.php'); require_once("mod/proxy.php"); @@ -655,7 +655,7 @@ function advanced_profile(&$a) { //show subcribed forum if it is enabled in the usersettings if (feature_enabled($uid,'forumlist_profile')) { - $profile['forumlist'] = array( t('Forums:'), forum::forumlist_profile_advanced($uid)); + $profile['forumlist'] = array( t('Forums:'), Forum::profile_advanced($uid)); } if ($a->profile['uid'] == local_user()) diff --git a/mod/network.php b/mod/network.php index 151384cd6..b72d72d78 100644 --- a/mod/network.php +++ b/mod/network.php @@ -114,7 +114,7 @@ function network_init(&$a) { require_once('include/group.php'); require_once('include/contact_widgets.php'); require_once('include/items.php'); - require_once('include/forum.php'); + require_once('include/Forum.php'); if(! x($a->page,'aside')) $a->page['aside'] = ''; @@ -148,7 +148,7 @@ function network_init(&$a) { } $a->page['aside'] .= (feature_enabled(local_user(),'groups') ? group_side('network/0','network','standard',$group_id) : ''); - $a->page['aside'] .= (feature_enabled(local_user(),'forumlist_widget') ? forum::widget_forumlist(local_user(),$cid) : ''); + $a->page['aside'] .= (feature_enabled(local_user(),'forumlist_widget') ? Forum::widget(local_user(),$cid) : ''); $a->page['aside'] .= posted_date_widget($a->get_baseurl() . '/network',local_user(),false); $a->page['aside'] .= networks_widget($a->get_baseurl(true) . '/network',(x($_GET, 'nets') ? $_GET['nets'] : '')); $a->page['aside'] .= saved_searches($search); diff --git a/mod/ping.php b/mod/ping.php index 3d34e2fe6..2abad13b0 100644 --- a/mod/ping.php +++ b/mod/ping.php @@ -1,7 +1,7 @@ user['uid'],true,$lastitem, true); + $contacts = Forum::get_list($a->user['uid'],true,$lastitem, true); $total = count($contacts); $visible_forums = 10;