20 $this->oProfileGen = &$oPr;
21 $this->aConfSite = $aSite;
22 $this->aConfDir = $aDir;
23 parent::__construct(
'profile');
27 $sThumbUrl =
$o ?
$o->get($oPr->_aProfile) :
'';
29 $GLOBALS[
'oSysTemplate']->setOpenGraphInfo(array(
34 $GLOBALS[
'oSysTemplate']->setOpenGraphInfo(array(
'image' => $sThumbUrl));
38 function genBlock( $iBlockID, $aBlock, $bStatic =
true, $sDynamicType =
'tab' )
41 $oPrivacy =
new ChWsbPrivacy(
'sys_page_compose_privacy',
'id',
'user_id');
43 $iPrivacyId = (int)
$GLOBALS[
'MySQL']->getOne(
"SELECT `id` FROM `sys_page_compose_privacy` WHERE `user_id`='" . $this->oProfileGen->_iProfileID .
"' AND `block_id`='" . $iBlockID .
"' LIMIT 1");
44 if($iPrivacyId != 0 && !$oPrivacy->check(
'view_block', $iPrivacyId, $this->iMemberID))
48 return parent::genBlock($iBlockID, $aBlock, $bStatic, $sDynamicType);
52 return $this->oProfileGen->showBlockCover(
'',
true);
56 return $this->oProfileGen->showBlockActionsMenu(
'',
true);
60 return $this->oProfileGen->showBlockFriendRequest(
'', $this,
true);
64 return $this->oProfileGen->showBlockPFBlock($iBlockID,
'',
$sContent,
true);
68 return $this->oProfileGen->showBlockRateProfile(
'',
true);
72 return $this->oProfileGen->showBlockFriends(
'', $this,
true);
76 return $this->oProfileGen->showBlockMutualFriends(
'',
true);
80 return $this->oProfileGen->showBlockComments(
'',
true);
85 return $this->oProfileGen->showBlockCmts();
98 foreach ($oPF->aBlocks
as $aBlock) {
99 foreach ($aBlock[
'Items']
as $a) {
100 if (
$sName == $a[
'Name']) {
118 if($this->iMemberID == $this->oProfileGen->_iProfileID) {
120 $sCode =
$GLOBALS[
'oSysTemplate']->parseHtmlByName(
'ps_page_chooser.html', array(
122 'page_name' => $this->sPageName,
123 'profile_id' => $this->oProfileGen->_iProfileID,
124 'block_id' => $iBlockID
129 return $sCode . parent::_getBlockCaptionCode($iBlockID, $aBlock, $aBlockCode, $bStatic, $sDynamicType);