function profilePage($iUserId, $sCss)
 {
     global $p_arr;
     $oProfile = new BxBaseProfileGenerator($iUserId);
     $oPPV = new BxTemplProfileView($oProfile, $site, $dir);
     $oProfile->oCmtsView->getExtraCss();
     $oProfile->oCmtsView->getExtraJs();
     $oProfile->oVotingView->getExtraJs();
     $p_arr = $oProfile->_aProfile;
     return $this->parseHtmlByName('profile_page.html', array('page_main_css' => $sCss, 'page_main_code' => $oPPV->getCode()));
 }
 function __construct(&$oPr, &$aSite, &$aDir)
 {
     $this->oProfileGen =& $oPr;
     $this->aConfSite = $aSite;
     $this->aConfDir = $aDir;
     parent::__construct('profile_private');
 }
 function BxDolProfilePrivatePageView(&$oPr, &$aSite, &$aDir)
 {
     $this->oProfileGen =& $oPr;
     $this->aConfSite = $aSite;
     $this->aConfDir = $aDir;
     parent::BxDolPageView('profile_private');
 }
Example #4
0
 function BxWallPage($sOwner, &$oWall)
 {
     $this->_sOwner = $sOwner;
     $this->_oWall =& $oWall;
     $this->oProfileGen = new BxBaseProfileGenerator(getId($sOwner, 0));
     $this->aConfSite = $GLOBALS['site'];
     $this->aConfDir = $GLOBALS['dir'];
     parent::BxDolPageView('wall');
 }
 /**
  * Class constructor ;
  */
 function BxDolProfileInfoPageView($sPageName, &$aMemberInfo)
 {
     global $site, $dir;
     $this->oProfileGen = new BxBaseProfileGenerator($aMemberInfo['ID']);
     $this->aConfSite = $site;
     $this->aConfDir = $dir;
     parent::BxDolPageView($sPageName);
     $this->iMemberID = getLoggedId();
     $this->aMemberInfo =& $aMemberInfo;
 }
Example #6
0
 function getCode()
 {
     if (!empty($this->_sOwner)) {
         $aOwner = $this->_oWall->_oDb->getUser($this->_sOwner, 'username');
         if ((int) $aOwner['id'] == 0) {
             return MsgBox(_t('_wall_msg_page_not_found'));
         }
     }
     return parent::getCode();
 }
Example #7
0
}
$oProfile = new BxBaseProfileGenerator($profileID);
$oProfile->oCmtsView->getExtraCss();
$oProfile->oCmtsView->getExtraJs();
$oProfile->oVotingView->getExtraJs();
$oSysTemplate->addJs('view_edit.js');
$_ni = 5;
$_page['name_index'] = $_ni;
$_page['css_name'] = array('profile_view.css', 'profile_view_tablet.css', 'profile_view_phone.css');
$p_arr = $oProfile->_aProfile;
$sUserInfo = $oFunctions->getUserInfo($p_arr['ID']);
if (!empty($sUserInfo)) {
    $sUserInfo = ': ' . htmlspecialchars_adv($sUserInfo);
}
$_page['header'] = process_line_output(getNickName($p_arr['ID'])) . $sUserInfo;
$oPPV = new BxTemplProfileView($oProfile, $site, $dir);
$_page_cont[$_ni]['page_main_code'] = $oPPV->getCode();
$_page_cont[$_ni]['custom_block'] = '';
$_page_cont[$_ni]['page_main_css'] = '';
// add profile customizer
if (BxDolInstallerUtils::isModuleInstalled("profile_customize")) {
    $_page_cont[$_ni]['custom_block'] = '<div id="profile_customize_page" style="display: none;">' . BxDolService::call('profile_customize', 'get_customize_block', array()) . '</div>';
    $_page_cont[$_ni]['page_main_css'] = '<style type="text/css">' . BxDolService::call('profile_customize', 'get_profile_style', array($profileID)) . '</style>';
}
// Submenu actions
$iId = $profileID;
$iMemberId = $memberID;
$sTxtProfileAccountPage = _t('_sys_am_profile_account_page');
$sTxtProfileMessage = _t('_sys_am_profile_message');
$sTxtFriendAdd = _t('_sys_am_profile_friend_add');
$sTxtFriendAccept = _t('_sys_am_profile_friend_accept');
    $_page_cont[0]['page_main_code'] = MsgBox(_t("_Profile NA"));
    PageCode();
    exit;
}
// Check if member can view profile
$contact_allowed = contact_allowed($memberID, $profileID);
$check_res = checkAction($memberID, ACTION_ID_VIEW_PROFILES, true, $profileID);
if ($check_res[CHECK_ACTION_RESULT] != CHECK_ACTION_RESULT_ALLOWED && !$logged['admin'] && !$logged['moderator'] && $memberID != $profileID && !$contact_allowed) {
    $_page['header'] = "{$site['title']} " . _t("_Member Profile");
    $_page['header_text'] = "{$site['title']} " . _t("_Member Profile");
    $_page['name_index'] = 0;
    $_page_cont[0]['page_main_code'] = '<center>' . $check_res[CHECK_ACTION_MESSAGE] . '</center><br />';
    PageCode();
    exit;
}
$oProfile = new BxTemplProfileView($profileID);
$_page['extra_js'] = $oTemplConfig->sTinyMceEditorMiniJS . $oProfile->oVotingView->getExtraJs() . $oProfile->oCmtsView->getExtraJs() . '<script type="text/javascript">urlIconLoading = "' . getTemplateIcon('loading.gif') . '";</script>';
$_page['extra_css'] = $oProfile->genProfileCSS($profileID) . $oProfile->oCmtsView->getExtraCss();
$p_arr = $oProfile->_aProfile;
if (!($p_arr['ID'] && ($logged['admin'] || $logged['moderator'] || $oProfile->owner || ($p_arr['Status'] = 'Active')))) {
    $_page['header'] = "{$site['title']} " . _t("_Member Profile");
    $_page['header_text'] = "{$site['title']} " . _t("_Member Profile");
    $_page['name_index'] = 0;
    $_page_cont[0]['page_main_code'] = '<div class="no_result"><div>' . _t("_Profile NA") . '.</div></div>';
    PageCode();
    exit;
}
$_page['header'] = process_line_output($p_arr['NickName']) . ": " . htmlspecialchars_adv($p_arr['Headline']);
//$_page['header_text'] = process_line_output( $p_arr['Headline'] );
// track profile views
if ($track_profile_view && $memberID && !$oProfile->owner) {
    $_page_cont[0]['page_main_code'] = MsgBox(_t("_Profile NA"));
    PageCode();
    exit;
}
// Check if member can view profile
$contact_allowed = contact_allowed($memberID, $profileID);
$check_res = checkAction($memberID, ACTION_ID_VIEW_PROFILES, true);
if ($check_res[CHECK_ACTION_RESULT] != CHECK_ACTION_RESULT_ALLOWED && !$logged['admin'] && !$logged['moderator'] && $memberID != $profileID && !$contact_allowed) {
    $_page['header'] = "{$site['title']} " . _t("_Member Profile");
    $_page['header_text'] = "{$site['title']} " . _t("_Member Profile");
    $_page['name_index'] = 0;
    $_page_cont[0]['page_main_code'] = '<center>' . $check_res[CHECK_ACTION_MESSAGE] . '</center><br />';
    PageCode();
    exit;
}
$oProfile = new BxTemplProfileView($profileID);
$_page['extra_js'] = $oTemplConfig->sTinyMceEditorMiniJS . $oProfile->oVotingView->getExtraJs() . '<script type="text/javascript">urlIconLoading = "' . getTemplateIcon('loading.gif') . '";</script>';
$_page['extra_css'] = $oProfile->genProfileCSS($profileID);
$p_arr = $oProfile->_aProfile;
if (!($p_arr['ID'] && ($logged['admin'] || $logged['moderator'] || $oProfile->owner || ($p_arr['Status'] = 'Active')))) {
    $_page['header'] = "{$site['title']} " . _t("_Member Profile");
    $_page['header_text'] = "{$site['title']} " . _t("_Member Profile");
    $_page['name_index'] = 0;
    $_page_cont[0]['page_main_code'] = '<div class="no_result"><div>' . _t("_Profile NA") . '.</div></div>';
    PageCode();
    exit;
}
//Ajax loaders
if ($_GET['show_only']) {
    switch ($_GET['show_only']) {
        case 'shareMusic':