function showBlockPhoto($iCol, $bNoDB = false) { if ($iCol == 1) { $iPID = $this->_iProfileID; $sNickName = $this->_aProfile['NickName']; } elseif ($iCol == 2) { if (!$this->_aProfile['Couple']) { return; } $iPID = $this->_iProfileID; //$iPID = (int)$this -> _aProfile['Couple']; $sNickName = $this->_aProfile['NickName'] . '(2)'; } $oPhotos = new ProfilePhotos($iPID); $oPhotos->getActiveMediaArray(); if ($this->_aProfile['Couple'] && $iCol != 1) { $aCoupleInfo = getProfileInfo($this->_aProfile['Couple']); if ($aCoupleInfo['Picture'] == 0) { $oPhotos = new ProfilePhotos($this->_aProfile['Couple']); $oPhotos->getActiveMediaArray(); } $ret = $oPhotos->getMediaBlock($aCoupleInfo['PrimPhoto'], true); } else { $ret = $oPhotos->getMediaBlock(0); } if ($bNoDB) { return DesignBoxContent(_t('_PROFILE Photos', $sNickName), $ret, 1); } else { echo DesignBoxContent(_t('_PROFILE Photos', $sNickName), $ret, 1); } }
function showBlockPhoto($sCaption) { global $memberID; global $p_arr; $oPhotos = new ProfilePhotos($this->_iProfileID); $oPhotos->getActiveMediaArray(); /* //perform photo voting if( $_REQUEST['voteSubmit'] && $_REQUEST['photoID'] ) { $oPhotos -> setVoting(); $oPhotos -> getActiveMediaArray(); } */ $iPhotoID = (int) $_REQUEST['photoID']; $ret = $oPhotos->getMediaBlock($iPhotoID); echo DesignBoxContent(_t($sCaption, $p_arr['NickName']), $ret, 1); }