function actionAlbumsViewMy($sParamValue = '', $sParamValue1 = '', $sParamValue2 = '', $sParamValue3 = '') { $sAction = bx_get('action'); if ($sAction !== false) { header('Content-Type: text/html; charset=UTF-8'); require_once 'BxFilesUploader.php'; $oUploader = new BxFilesUploader(); switch ($sAction) { case 'cancel_file': echo $oUploader->serviceCancelFileInfo(); return; case 'accept_file_info': echo $oUploader->serviceAcceptFileInfo(); return; default: parent::processUpload($oUploader, $sAction); return; } } $bNotAllowView = $this->_iProfileId == 0 || !isLoggedActive(); $aAlbumInfo = array(); if (!$bNotAllowView && !empty($sParamValue1)) { $aAlbumInfo = $this->oAlbums->getAlbumInfo(array('fileUri' => $sParamValue1, 'owner' => $this->_iProfileId)); if (!empty($aAlbumInfo)) { $bNotAllowView = $aAlbumInfo['AllowAlbumView'] == BX_DOL_PG_HIDDEN; } } if ($bNotAllowView) { $sKey = _t('_' . $this->_oConfig->getMainPrefix() . '_access_denied'); $this->_oTemplate->pageCode($this->aPageTmpl, array('page_main_code' => DesignBoxContent($sKey, MsgBox($sKey), 1)), '', '', false); return; } if (is_array($_POST['entry'])) { foreach ($_POST['entry'] as $iValue) { $iValue = (int) $iValue; switch (true) { case isset($_POST['action_delete']): $iCount = $this->_deleteAlbumUnits($iValue); if ($iCount == 0) { $this->oAlbums->removeAlbum($iValue); } break; case isset($_POST['action_move_to']): $this->oAlbums->moveObject((int) $_POST['album_id'], (int) $_POST['new_album'], $iValue); break; case isset($_POST['action_delete_object']): $this->_deleteFile($iValue); break; } } } bx_import('PageAlbumsMy', $this->_aModule); $sClassName = $this->_oConfig->getClassPrefix() . 'PageAlbumsMy'; $oPage = new $sClassName($this, $this->_iProfileId, array($sParamValue, $sParamValue1, $sParamValue2, $sParamValue3)); $sCode = $oPage->getCode(); switch ($sParamValue) { case 'main': bx_import('PageAlbumsOwner', $this->_aModule); $sClassName = $this->_oConfig->getClassPrefix() . 'PageAlbumsOwner'; $oPage = new $sClassName($this, array('browse', 'owner', getUsername($this->_iProfileId))); $sCode .= $oPage->getCode(); break; case 'main_objects': $sCode .= $this->getAlbumPageView($aAlbumInfo); break; } $GLOBALS['oTopMenu']->setCurrentProfileID($this->_iProfileId); $this->_oTemplate->pageCode($this->aPageTmpl, array('page_main_code' => $sCode), '', '', false); }