当前位置: 首页>>代码示例>>PHP>>正文


PHP BxDolModuleDb类代码示例

本文整理汇总了PHP中BxDolModuleDb的典型用法代码示例。如果您正苦于以下问题:PHP BxDolModuleDb类的具体用法?PHP BxDolModuleDb怎么用?PHP BxDolModuleDb使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了BxDolModuleDb类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: MlClonetwoPageFields

 function MlClonetwoPageFields($iAreaID)
 {
     global $site;
     $this->sCacheFile = BX_DIRECTORY_PATH_DBCACHE . 'db_' . 'ml_clonetwo_fields' . '_' . md5($site['ver'] . $site['build'] . $site['url']) . '.php';
     $this->iAreaID = $iAreaID;
     switch ($this->iAreaID) {
         case 1:
             $this->areaPageName = 'Join';
             break;
         case 2:
             $this->areaPageName = 'Edit';
             break;
         case 5:
             $this->areaPageName = 'View';
             break;
     }
     if (!$this->loadCache()) {
         return false;
     }
     $oModuleDb = new BxDolModuleDb();
     $this->_aModule = $oModuleDb->getModuleByUri('clonetwo');
     $this->_oMain = new MlClonetwoModule($this->_aModule);
     $sDelimeter = getParam('ml_clonetwo_multi_divider');
     $this->_sDelimeter = $sDelimeter ? $sDelimeter : ';';
     $this->_iProfileId = getLoggedId();
     $this->_aMedia = array('photos' => array('post' => 'ready_images', 'upload_func' => 'uploadPhotos', 'tag' => BX_WELLS_PHOTOS_TAG, 'cat' => BX_WELLS_PHOTOS_CAT, 'thumb' => 'thumb', 'module' => 'photos', 'title_upload_post' => 'images_titles', 'title_upload' => _t('_ml_clonetwo_form_caption_file_title'), 'service_method' => 'get_photo_array'), 'videos' => array('post' => 'ready_videos', 'upload_func' => 'uploadVideos', 'tag' => BX_WELLS_VIDEOS_TAG, 'cat' => BX_WELLS_VIDEOS_CAT, 'thumb' => false, 'module' => 'videos', 'title_upload_post' => 'videos_titles', 'title_upload' => _t('_ml_clonetwo_form_caption_file_title'), 'service_method' => 'get_video_array'), 'sounds' => array('post' => 'ready_sounds', 'upload_func' => 'uploadSounds', 'tag' => BX_WELLS_SOUNDS_TAG, 'cat' => BX_WELLS_SOUNDS_CAT, 'thumb' => false, 'module' => 'sounds', 'title_upload_post' => 'sounds_titles', 'title_upload' => _t('_ml_clonetwo_form_caption_file_title'), 'service_method' => 'get_music_array'), 'files' => array('post' => 'ready_files', 'upload_func' => 'uploadFiles', 'tag' => BX_WELLS_FILES_TAG, 'cat' => BX_WELLS_FILES_CAT, 'thumb' => false, 'module' => 'files', 'title_upload_post' => 'files_titles', 'title_upload' => _t('_ml_clonetwo_form_caption_file_title'), 'service_method' => 'get_file_array'));
 }
开发者ID:scriptologist,项目名称:Multi-Module-Creator-Plus,代码行数:27,代码来源:MlClonetwoPageFields.php

示例2: processing

 function processing()
 {
     $oModules = new BxDolModuleDb();
     $aModules = $oModules->getModules();
     $aResult = array();
     foreach ($aModules as $aModule) {
         $aCheckInfo = BxDolInstallerUi::checkForUpdates($aModule);
         if (isset($aCheckInfo['version'])) {
             $aResult[] = _t('_adm_txt_modules_update_text_ext', $aModule['title'], $aCheckInfo['version']);
         }
     }
     if (empty($aResult)) {
         return;
     }
     $aAdmins = $GLOBALS['MySQL']->getAll("SELECT * FROM `Profiles` WHERE `Role`&" . BX_DOL_ROLE_ADMIN . "<>0 AND `EmailNotify`='1'");
     if (empty($aAdmins)) {
         return;
     }
     $oEmailTemplate = new BxDolEmailTemplates();
     $sMessage = implode('<br />', $aResult);
     foreach ($aAdmins as $aAdmin) {
         $aTemplate = $oEmailTemplate->getTemplate('t_ModulesUpdates', $aAdmin['ID']);
         sendMail($aAdmin['Email'], $aTemplate['Subject'], $aTemplate['Body'], $aAdmin['ID'], array('MessageText' => $sMessage));
     }
 }
开发者ID:toxalot,项目名称:dolphin.pro,代码行数:25,代码来源:BxDolCronModules.php

示例3: __construct

 function __construct($aCustomForm)
 {
     if (isset($aCustomForm['inputs']['allow_post_in_forum_to']['type'])) {
         $oModuleDb = new BxDolModuleDb();
         if (!$oModuleDb->getModuleByUri('forum')) {
             $aCustomForm['inputs']['allow_post_in_forum_to']['type'] = 'hidden';
         }
     }
     parent::__construct($aCustomForm);
 }
开发者ID:toxalot,项目名称:dolphin.pro,代码行数:10,代码来源:BxDolFormMedia.php

示例4: call

 public static function call($mixed, $sMethod, $aParams = array(), $sClass = 'Module')
 {
     $oDb = new BxDolModuleDb();
     if (is_string($mixed)) {
         $aModule = $oDb->getModuleByUri($mixed);
     } else {
         $aModule = $oDb->getModuleById($mixed);
     }
     return empty($aModule) ? '' : BxDolRequest::processAsService($aModule, $sMethod, $aParams, $sClass);
 }
开发者ID:Prashank25,项目名称:dolphin.pro,代码行数:10,代码来源:BxDolService.php

示例5: BxDolFormMedia

 function BxDolFormMedia($aCustomForm)
 {
     if (isset($aCustomForm['inputs']['allow_post_in_forum_to']['type'])) {
         $oModuleDb = new BxDolModuleDb();
         if (!$oModuleDb->getModuleByUri('forum')) {
             $aCustomForm['inputs']['allow_post_in_forum_to']['type'] = 'hidden';
         }
     }
     parent::BxTemplFormView($aCustomForm);
 }
开发者ID:Gotgot59,项目名称:dolphin.pro,代码行数:10,代码来源:BxDolFormMedia.php

示例6: getBlockCode_ForumFeed

 function getBlockCode_ForumFeed()
 {
     if (!$this->_oMain->isAllowedReadForum($this->aDataEntry)) {
         return '';
     }
     $oModuleDb = new BxDolModuleDb();
     if (!$oModuleDb->getModuleByUri('forum')) {
         return '';
     }
     $sRssId = 'forum|' . $this->_oConfig->getUri() . '|' . rawurlencode($this->aDataEntry[$this->_oDb->_sFieldUri]);
     return '<div class="RSSAggrCont" rssid="' . $sRssId . '" rssnum="8" member="' . getLoggedId() . '">' . $GLOBALS['oFunctions']->loadingBoxInline() . '</div>';
 }
开发者ID:Prashank25,项目名称:dolphin.pro,代码行数:12,代码来源:BxDolTwigPageView.php

示例7: isActive

 public function isActive()
 {
     if (empty($this->_sActiveUri)) {
         return false;
     }
     bx_import('BxDolModuleDb');
     $oModuleDb = new BxDolModuleDb();
     if (!$oModuleDb->isModule($this->_sActiveUri)) {
         return false;
     }
     return true;
 }
开发者ID:Prashank25,项目名称:dolphin.pro,代码行数:12,代码来源:BxDolPayments.php

示例8: getMemberMenuAdsList

function getMemberMenuAdsList($iID)
{
    $oMemberMenu = bx_instance('BxDolMemberMenu');
    $oModuleDb = new BxDolModuleDb();
    $aModule = $oModuleDb->getModuleByUri('ads');
    $oAds = new BxAdsModule($aModule);
    $sAdsMainLink = $oAds->bUseFriendlyLinks ? BX_DOL_URL_ROOT . 'ads/my_page/' : "{$oAds->sCurrBrowsedFile}?action=my_page";
    $iMyAdsCnt = $oAds->_oDb->getMemberAdsCnt($iID);
    // language keys;
    $aLanguageKeys = array('ads' => _t('_bx_ads_Ads'));
    // fill all necessary data;
    $aLinkInfo = array('item_img_src' => $oAds->_oTemplate->getIconUrl('ads.png'), 'item_img_alt' => $aLanguageKeys['ads'], 'item_link' => $sAdsMainLink, 'item_onclick' => null, 'item_title' => $aLanguageKeys['ads'], 'extra_info' => $iMyAdsCnt);
    return $oMemberMenu->getGetExtraMenuLink($aLinkInfo);
}
开发者ID:dalinhuang,项目名称:shopexts,代码行数:14,代码来源:ads_get_member_menu_list.php

示例9: BxPollDb

 function BxPollDb(&$oConfig)
 {
     parent::BxDolModuleDb();
     $this->_oConfig = $oConfig;
     $this->_sTable = $oConfig->sTableName;
     $this->sTablePrefix = $oConfig->sTablePrefix;
 }
开发者ID:dalinhuang,项目名称:shopexts,代码行数:7,代码来源:BxPollDb.php

示例10: actionCheckPayment

 function actionCheckPayment($bInstall = true)
 {
     if (!$bInstall) {
         return BX_DOL_INSTALLER_SUCCESS;
     }
     $aError = array('code' => BX_DOL_INSTALLER_FAILED, 'content' => _t('_adm_txt_modules_wrong_dependency_install_payment'));
     $sPayment = getParam('sys_default_payment');
     if (empty($sPayment)) {
         return $aError;
     }
     $oModuleDb = new BxDolModuleDb();
     $aPayment = $oModuleDb->getModuleByUri($sPayment);
     if (empty($aPayment) || !is_array($aPayment)) {
         return $aError;
     }
     return BX_DOL_INSTALLER_SUCCESS;
 }
开发者ID:toxalot,项目名称:dolphin.pro,代码行数:17,代码来源:installer.php

示例11: BxDolFilesDb

 function BxDolFilesDb(&$oConfig)
 {
     parent::BxDolModuleDb($oConfig);
     $this->_oConfig =& $oConfig;
     $this->iViewer = getLoggedId();
     $this->aFileFields = array('medID' => 'ID', 'Categories' => 'Categories', 'medProfId' => 'Owner', 'medTitle' => 'Title', 'medUri' => 'Uri', 'medDesc' => 'Description', 'medTags' => 'Tags', 'medDate' => 'Date', 'medViews' => 'Views', 'Approved' => 'Status', 'Featured' => 'Featured', 'Rate' => 'Rate', 'RateCount' => 'RateCount');
     $this->aFavoriteFields = array('fileId' => 'ID', 'ownerId' => 'Profile', 'favDate' => 'Date');
 }
开发者ID:dalinhuang,项目名称:shopexts,代码行数:8,代码来源:BxDolFilesDb.php

示例12: getNotInstalled

 function getNotInstalled($sResult)
 {
     //--- Get Items ---//
     $oModules = new BxDolModuleDb();
     $aModules = $oModules->getModules();
     $aInstalled = array();
     foreach ($aModules as $aModule) {
         $aInstalled[] = $aModule['path'];
     }
     $aNotInstalled = array();
     $sPath = BX_DIRECTORY_PATH_ROOT . 'modules/';
     if ($rHandleVendor = opendir($sPath)) {
         while (($sVendor = readdir($rHandleVendor)) !== false) {
             if (substr($sVendor, 0, 1) == '.' || !is_dir($sPath . $sVendor)) {
                 continue;
             }
             if ($rHandleModule = opendir($sPath . $sVendor)) {
                 while (($sModule = readdir($rHandleModule)) !== false) {
                     if (!is_dir($sPath . $sVendor . '/' . $sModule) || substr($sModule, 0, 1) == '.' || in_array($sVendor . '/' . $sModule . '/', $aInstalled)) {
                         continue;
                     }
                     $sConfigPath = $sPath . $sVendor . '/' . $sModule . '/install/config.php';
                     if (!file_exists($sConfigPath)) {
                         continue;
                     }
                     include $sConfigPath;
                     $aNotInstalled[$aConfig['title']] = array('name' => $aConfig['home_uri'], 'value' => $aConfig['home_dir'], 'title' => _t('_adm_txt_modules_title_module', $aConfig['title'], !empty($aConfig['version']) ? $aConfig['version'] : $this->_sDefVersion, $aConfig['vendor']), 'bx_if:update' => array('condition' => false, 'content' => array()), 'bx_if:latest' => array('condition' => false, 'content' => array()));
                 }
                 closedir($rHandleModule);
             }
         }
         closedir($rHandleVendor);
     }
     ksort($aNotInstalled);
     //--- Get Controls ---//
     $aButtons = array('modules-install' => _t('_adm_btn_modules_install'), 'modules-delete' => _t('_adm_btn_modules_delete'));
     $sControls = BxTemplSearchResult::showAdminActionsPanel('modules-not-installed-form', $aButtons, 'pathes');
     if (!empty($sResult)) {
         $sResult = MsgBox(_t($sResult), 3);
     }
     return $sResult . $GLOBALS['oAdmTemplate']->parseHtmlByName('modules_list.html', array('type' => 'not-installed', 'bx_repeat:items' => $aNotInstalled, 'controls' => $sControls));
 }
开发者ID:dalinhuang,项目名称:shopexts,代码行数:42,代码来源:BxDolInstallerUi.php

示例13: checkForUpdatesByPath

 function checkForUpdatesByPath($sPath)
 {
     bx_import('BxDolModuleDb');
     $oModuleDb = new BxDolModuleDb();
     $aModule = $oModuleDb->getModulesBy(array('type' => 'path', 'value' => $sPath));
     $aResult = self::checkForUpdates($aModule);
     $aResult['content'] = $this->_parseUpdate($aResult);
     return $aResult;
 }
开发者ID:Gotgot59,项目名称:dolphin.pro,代码行数:9,代码来源:BxDolInstallerUi.php

示例14: MlModCreatorDb

 function MlModCreatorDb(&$oConfig)
 {
     parent::BxDolModuleDb();
     $this->_sPrefix = $oConfig->getDbPrefix();
 }
开发者ID:scriptologist,项目名称:Multi-Module-Creator-Plus,代码行数:5,代码来源:MlModCreatorDb.php

示例15: getChatBox

 /**
  * Function will generate chat block for current member ;
  *
  * @param  : $iSender (integer)     - sender member's Id;
  * @return : (array);
  */
 function getChatBox($iSender)
 {
     global $oFunctions;
     $iSender = (int) $iSender;
     $oModuleDb = new BxDolModuleDb();
     $oUserStatus = new BxDolUserStatusView();
     $sMemberThumb = $oFunctions->getMemberThumbnail($iSender, 'none');
     $sMemberIcon = $oFunctions->getMemberIcon($iSender, 'none', false, '_plain');
     $aSenderInfo = getProfileInfo($iSender);
     $sSenderLink = getProfileLink($iSender);
     $sStatusIcon = $oUserStatus->getStatusIcon($iSender);
     // language keys;
     $aLanguageKeys = array('minimize' => _t('_simple_messenger_minimize_button'), 'close' => _t('_simple_messenger_close_button'), 'video_mess' => _t('_simple_messenger_switch_to_video'));
     // contain data for sender block;
     $aSenderBlock = array('sender_thumb' => $sMemberThumb, 'sender_link' => $sSenderLink, 'status_text' => $aSenderInfo['UserStatusMessage'], 'sender_nick' => getNickName($aSenderInfo['ID']), 'reduce_title' => $aLanguageKeys['minimize'], 'close_title' => $aLanguageKeys['close'], 'history_window_id' => $this->aCoreSettings['history_block_prefix'] . $iSender, 'sender_id' => $iSender, 'bx_if:video_messenger' => array('condition' => $oModuleDb->isModule('messenger'), 'content' => array('sender_id' => $this->iLoggedMemberId, 'sender_passw' => getPassword($this->iLoggedMemberId), 'recipient_id' => $iSender, 'video_messenger' => $aLanguageKeys['video_mess'])));
     $aMessagesList = $this->getMessagesHistory($this->iLoggedMemberId, $iSender, 0, false);
     // process nick name;
     $sNickName = getNickName($aSenderInfo['ID']);
     if (mb_strlen($sNickName) > $this->iMaxNickLength) {
         $sNickName = mb_substr($sNickName, 0, $this->iMaxNickLength) . '...';
     }
     $aTemplateKeys = array('block_indent' => $this->sMemberMenuPosition == 'bottom' ? 'bottom_indent' : 'top_indent', 'chat_block_position' => $this->sMemberMenuPosition == 'bottom' ? 'chat_block_bottom_position' : 'chat_block_top_position', 'sender_nick' => $sNickName, 'sender_icon' => $sMemberIcon, 'member_status' => $sStatusIcon, 'history_window_id' => $this->aCoreSettings['history_block_prefix'] . $iSender, 'history_block_position' => $this->sMemberMenuPosition == 'bottom' ? 'history_bottom_position' : 'history_top_position', 'recipient_id' => $iSender, 'bx_if:menu_pos_top' => array('condition' => $this->sMemberMenuPosition == 'bottom', 'content' => $aSenderBlock), 'bx_if:menu_pos_bottom' => array('condition' => $this->sMemberMenuPosition != 'bottom', 'content' => $aSenderBlock), 'messages' => $aMessagesList['messages_list']);
     // generate the chat box's content;
     $sOutputCode = $this->_oTemplate->parseHtmlByName('chat_block.html', $aTemplateKeys);
     $aRetArray = array('chat_box' => $sOutputCode, 'last_message' => $aMessagesList['last_message'], 'count_messages' => $aMessagesList['count_messages']);
     return $aRetArray;
 }
开发者ID:Gotgot59,项目名称:dolphin.pro,代码行数:33,代码来源:BxSimpleMessengerModule.php


注:本文中的BxDolModuleDb类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。