$o = '';
$location = false;
$address = false;
- $pdesc = true;
+// $pdesc = true;
if((! is_array($profile)) && (! count($profile)))
return $o;
);
}
- if((x($profile['page-flags']) == 1)
- || (x($profile['page-flags']) == 2)
- || (x($profile['page-flags']) == 5))
- $account_type = page_type_translate($profile['page-flags']);
-
- if(! $account_type)
- $account_type = (x($profile['forum']) || x($profile['prv']) || (x($profile['community'])) ? t('Forum') : "");
+ // check if profile is a forum
+ if((x($profile['page-flags']) == 2)
+ || (x($profile['page-flags']) == 5)
+ || (x($profile['forum']))
+ || (x($profile['prv']))
+ || (x($profile['community'])))
+ $account_type = t('Forum');
+ else
+ $account_type = "";
if((x($profile,'address') == 1)
|| (x($profile,'locality') == 1)
'$account_type' => $account_type,
'$location' => $location,
'$gender' => $gender,
- '$pdesc' => $pdesc,
+// '$pdesc' => $pdesc,
'$marital' => $marital,
'$homepage' => $homepage,
'$about' => $about,
);
}
+ if ((! $is_owner) && ((count($a->profile)) || (! $a->profile['hide-friends']))) {
+ $tabs[] = array(
+ 'label' => t('Contacts'),
+ 'url' => $a->get_baseurl() . '/viewcontacts/' . $nickname,
+ 'sel' => ((!isset($tab)&&$a->argv[0]=='viewcontacts')?'active':''),
+ 'title' => t('Contacts'),
+ 'id' => 'viewcontacts-tab',
+ 'accesskey' => 'k',
+ );
+ }
$arr = array('is_owner' => $is_owner, 'nickname' => $nickname, 'tab' => (($tab) ? $tab : false), 'tabs' => $tabs);
call_hooks('profile_tabs', $arr);