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


PHP MAX::constructURL方法代码示例

本文整理汇总了PHP中MAX::constructURL方法的典型用法代码示例。如果您正苦于以下问题:PHP MAX::constructURL方法的具体用法?PHP MAX::constructURL怎么用?PHP MAX::constructURL使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在MAX的用法示例。


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

示例1: errorObjToString

    /**
     * A method to convert PEAR_Error objects to strings.
     *
     * @static
     * @param PEAR_Error $oError A {@link PEAR_Error} object
     */
    function errorObjToString($oError, $additionalInfo = null)
    {
        $aConf = $GLOBALS['_MAX']['CONF'];
        $message = htmlspecialchars($oError->getMessage());
        $debugInfo = htmlspecialchars($oError->getDebugInfo());
        $additionalInfo = htmlspecialchars($additionalInfo);
        $level = $oError->getCode();
        $errorType = MAX::errorConstantToString($level);
        $img = MAX::constructURL(MAX_URL_IMAGE, 'errormessage.gif');
        // Message
        $output = <<<EOF
<br />
<div class="errormessage">
    <img class="errormessage" src="{$img}" align="absmiddle">
    <span class='tab-r'>{$errorType} Error</span>
    <br />
    <br />{$message}
    <br /><pre>{$debugInfo}</pre>
    {$additionalInfo}
</div>
<br />
<br />
EOF;
        return $output;
    }
开发者ID:akirsch,项目名称:revive-adserver,代码行数:31,代码来源:Max.php

示例2: init

 function init($templateName)
 {
     $this->template_dir = MAX_PATH . '/lib/templates/admin';
     $this->compile_dir = MAX_PATH . '/var/templates_compiled';
     $this->cache_dir = MAX_PATH . '/var/cache';
     $this->caching = 0;
     $this->cache_lifetime = 3600;
     $this->register_function('t', array('OA_Admin_Template', '_function_t'));
     $this->register_function('tabindex', array('OA_Admin_Template', '_function_tabindex'));
     $this->register_function('oa_icon', array('OA_Admin_Template', '_function_oa_icon'));
     $this->register_function('oa_title_sort', array('OA_Admin_Template', '_function_oa_title_sort'));
     $this->register_function('ox_column_title', array('OA_Admin_Template', '_function_ox_column_title'));
     $this->register_function('ox_column_class', array('OA_Admin_Template', '_function_ox_column_class'));
     $this->register_function('ox_campaign_type', array('OA_Admin_Template', '_function_ox_campaign_type'));
     $this->register_function('ox_campaign_status', array('OA_Admin_Template', '_function_ox_campaign_status'));
     $this->register_function('ox_campaign_icon', array('OA_Admin_Template', '_function_ox_campaign_icon'));
     $this->register_function('ox_banner_size', array('OA_Admin_Template', '_function_ox_banner_size'));
     $this->register_function('ox_banner_icon', array('OA_Admin_Template', '_function_ox_banner_icon'));
     $this->register_function('ox_zone_size', array('OA_Admin_Template', '_function_ox_zone_size'));
     $this->register_function('ox_zone_icon', array('OA_Admin_Template', '_function_ox_zone_icon'));
     $this->register_function('ox_tracker_type', array('OA_Admin_Template', '_function_ox_tracker_type'));
     $this->register_function('ox_entity_id', array('OA_Admin_Template', '_function_ox_entity_id'));
     $this->register_function('boldSearchPhrase', array('OA_Admin_Template', '_function_boldSearchPhrase'));
     $this->register_function('oa_is_admin', array('OA_Admin_Template', '_function_oa_is_admin'));
     $this->register_function('oa_is_manager', array('OA_Admin_Template', '_function_oa_is_manager'));
     $this->register_function('oa_is_advertiser', array('OA_Admin_Template', '_function_oa_is_advertiser'));
     $this->register_function('oa_is_trafficker', array('OA_Admin_Template', '_function_oa_is_trafficker'));
     $this->register_function('phpAds_ShowBreak', array('OA_Admin_Template', '_function_phpAds_ShowBreak'));
     $this->register_function('phpAds_DelConfirm', array('OA_Admin_Template', '_function_phpAds_DelConfirm'));
     $this->register_function('MAX_zoneDelConfirm', array('OA_Admin_Template', '_function_MAX_zoneDelConfirm'));
     $this->register_function('showStatusText', array('OA_Admin_Template', '_function_showStatusText'));
     $this->register_function('showCampaignType', array('OA_Admin_Template', '_function_showCampaignType'));
     $this->register_function('oa_form_input_attributes', array('OA_Admin_Template', '_function_form_input_attributes'));
     $this->register_block('oa_edit', array('OA_Admin_Template', '_block_edit'));
     $this->register_block('oa_form_element', array('OA_Admin_Template', '_block_form_element'));
     $this->templateName = $templateName;
     $this->assign('phpAds_TextDirection', $GLOBALS['phpAds_TextDirection']);
     $this->assign('phpAds_TextAlignLeft', $GLOBALS['phpAds_TextAlignLeft']);
     $this->assign('phpAds_TextAlignRight', $GLOBALS['phpAds_TextAlignRight']);
     $this->assign('assetPath', OX::assetPath());
     $this->assign("adminWebPath", MAX::constructURL(MAX_URL_ADMIN, ''));
     $this->assign("oaTemplateDir", MAX_PATH . '/lib/templates/admin/');
     //for pluggable page elements
     //- plugins may need to refrence their JS in OXP page templates
     $this->assign("adminPluginWebPath", MAX::constructURL(MAX_URL_ADMIN, 'plugins'));
     //- plugins may need to inject their own
     //template based elements into normal templates
     $this->assign("pluginBaseDir", MAX_PATH . '/www/admin/plugins/');
     $this->assign("pluginTemplateDir", '/templates/');
     /**
      * CVE-2013-5954
      *
      * Register the helper method to allow the the required session token to
      * be placed into GET method calls for CRUD operations in templates. See
      * OA_Permission::checkSessionToken() method for details.
      */
     $this->register_function('rv_add_session_token', array('OA_Admin_Template', '_add_session_token'));
 }
开发者ID:hostinger,项目名称:revive-adserver,代码行数:58,代码来源:Template.php

示例3: display

 /**
  * A method to launch and display the widget
  *
  */
 function display()
 {
     $oTpl = new OA_Admin_Template('dashboard/grid.html');
     $oTpl->assign('dashboardURL', MAX::constructURL(MAX_URL_ADMIN, 'dashboard.php'));
     $oTpl->assign('cssURL', OX::assetPath() . "/css");
     $oTpl->assign('imageURL', OX::assetPath() . "/images");
     $oTpl->assign('jsURL', OX::assetPath() . "/js");
     $oTpl->display();
 }
开发者ID:hostinger,项目名称:revive-adserver,代码行数:13,代码来源:Grid.php

示例4: test_constructURL_Includes_Nonstandard_Secure_Port_Number

 function test_constructURL_Includes_Nonstandard_Secure_Port_Number()
 {
     $http = $GLOBALS['_MAX']['HTTP'];
     $GLOBALS['_MAX']['HTTP'] = 'https://';
     $_SERVER['SERVER_PORT'] = 4430;
     $GLOBALS['_MAX']['CONF']['openads']['sslPort'] = 4430;
     $url = MAX::constructURL(MAX_URL_ADMIN, 'test.html');
     $this->assertEqual($url, 'https://www.maxstore.net:4430/www/admin/test.html', "A non-standard port number should be explicitly provided in delivery URLs. %s");
     $GLOBALS['_MAX']['HTTP'] = $http;
 }
开发者ID:Spark-Eleven,项目名称:revive-adserver,代码行数:10,代码来源:max.lib.test.php

示例5: getLogoutUrl

 /**
  * If the agency has set the logout URL in a database, returns this URL
  * (trimmed).
  * Otherwise, returns 'index.php'.
  *
  * @param string $agencyId
  * @return string Url for redirection after logout.
  */
 function getLogoutUrl($agencyId)
 {
     $doAgency = null;
     if ($agencyId) {
         $doAgency = OA_Dal::staticGetDO('agency', $agencyId);
     }
     if ($doAgency && !empty($doAgency->logout_url)) {
         return trim($doAgency->logout_url);
     }
     return MAX::constructURL(MAX_URL_ADMIN, 'index.php');
 }
开发者ID:villos,项目名称:tree_admin,代码行数:19,代码来源:Agency.php

示例6: redirectIfNecessary

 function redirectIfNecessary($adminPage)
 {
     $oDesiredUrl = new MAX_Url();
     $oCurrentUrl = new MAX_Url();
     $full_desired_url_string = MAX::constructURL(MAX_URL_ADMIN, $adminPage);
     $oDesiredUrl->useValuesFromString($full_desired_url_string);
     $oCurrentUrl->useValuesFromServerVariableArray($_SERVER);
     if ($oDesiredUrl->equals($oCurrentUrl)) {
         return;
     }
     $this->redirect($adminPage);
 }
开发者ID:villos,项目名称:tree_admin,代码行数:12,代码来源:Redirect.php

示例7: display

 /**
  * A method to launch and display the widget
  *
  */
 function display()
 {
     $aConf = $GLOBALS['_MAX']['CONF'];
     phpAds_PageHeader(null, new OA_Admin_UI_Model_PageHeaderModel(), '', false, false);
     $oTpl = new OA_Admin_Template('dashboard/main.html');
     if (!$aConf['ui']['dashboardEnabled'] || !$aConf['sync']['checkForUpdates']) {
         $dashboardUrl = MAX::constructURL(MAX_URL_ADMIN, 'dashboard.php?widget=Disabled');
     } else {
         $dashboardUrl = MAX::constructURL(MAX_URL_ADMIN, 'dashboard.php?widget=Grid');
     }
     $oTpl->assign('dashboardURL', $dashboardUrl);
     $oTpl->display();
     phpAds_PageFooter('', true);
 }
开发者ID:Jaree,项目名称:revive-adserver,代码行数:18,代码来源:Index.php

示例8: assetPath

 /**
  * A method to construct URLs for static assets, such as images, CSS and
  * JavaScript files, based on OpenX installation and configuration details.
  *
  * @param string $asset An optional relative path to the asset.
  * @return string       The URL to the asset. If asset was not provided,
  * 		                the path does not contain a trailing slash.
  */
 function assetPath($asset = null)
 {
     global $installing;
     $aConf = $GLOBALS['_MAX']['CONF'];
     $assetsVersion = $aConf['webpath']['adminAssetsVersion'];
     $prefix = $installing ? '' : MAX::constructURL(MAX_URL_ADMIN, '');
     $pathWithSuffix = $prefix . "assets";
     if (strlen($assetsVersion)) {
         $pathWithSuffix .= "/" . $assetsVersion;
     }
     if ($asset != null) {
         return $pathWithSuffix . "/" . $asset;
     } else {
         return $pathWithSuffix;
     }
 }
开发者ID:ballistiq,项目名称:revive-adserver,代码行数:24,代码来源:OX.php

示例9: display

 /**
  * A method to launch and display the widget
  *
  */
 function display()
 {
     $aConf = $GLOBALS['_MAX']['CONF'];
     phpAds_PageHeader(null, new OA_Admin_UI_Model_PageHeaderModel(), '', false, false);
     $oTpl = new OA_Admin_Template('dashboard/main.html');
     if (!$aConf['ui']['dashboardEnabled'] || !$aConf['sync']['checkForUpdates']) {
         $dashboardUrl = MAX::constructURL(MAX_URL_ADMIN, 'dashboard.php?widget=Disabled');
     } else {
         $m2mTicket = OA_Dal_Central_M2M::getM2MTicket(OA_Permission::getAccountId());
         if (empty($m2mTicket)) {
             $dashboardUrl = MAX::constructURL(MAX_URL_ADMIN, 'dashboard.php?widget=Reload');
         } else {
             $dashboardUrl = $this->buildDashboardUrl($m2mTicket, null, '&amp;');
         }
     }
     $oTpl->assign('dashboardURL', $dashboardUrl);
     $oTpl->display();
     phpAds_PageFooter('', true);
 }
开发者ID:villos,项目名称:tree_admin,代码行数:23,代码来源:Index.php

示例10: _prepareCampaignActivatedDeactivatedEmailBody

 /**
  * A private method to prepare the body of an advertiser's "campaign activated"
  * or "campaign deactivated" report email.
  *
  * @access private
  * @param integer $advertiserId The advertiser's ID.
  * @param array   $acampaign    The campaign details.
  */
 function _prepareCampaignActivatedDeactivatedEmailBody($aCampaign)
 {
     // Load the "Campaign" and "Banner" strings, and prepare formatting strings
     global $strCampaign, $strBanner;
     $strCampaignLength = strlen($strCampaign);
     $strBannerLength = strlen($strBanner);
     $maxLength = max($strCampaignLength, $strBannerLength);
     $strCampaignPrint = '%-' . $maxLength . 's';
     $strBannerPrint = ' %-' . ($maxLength - 1) . 's';
     // Load remaining strings
     global $strLinkedTo;
     // Prepare the result
     $emailBody = '';
     // Add the name of the campaign to the report
     $emailBody .= "\n" . sprintf($strCampaignPrint, $strCampaign) . ' ';
     $emailBody .= strip_tags(phpAds_buildName($aCampaign['campaignid'], $aCampaign['campaignname'])) . "\n";
     // Add a URL link to the stats page of the campaign
     $page = 'stats.php?clientid=' . $aCampaign['clientid'] . '&campaignid=' . $aCampaign['campaignid'] . '&statsBreakdown=day&entity=campaign&breakdown=history&period_preset=all_stats&period_start=&period_end=';
     $emailBody .= MAX::constructURL(MAX_URL_ADMIN, $page) . "\n";
     // Add a nice divider
     $emailBody .= "=======================================================\n\n";
     // Fetch all ads in the campaign
     $doBanners = OA_Dal::factoryDO('banners');
     $doBanners->campaignid = $aCampaign['campaignid'];
     $doBanners->orderBy('bannerid');
     $doBanners->find();
     if ($doBanners->getRowCount() > 0) {
         while ($doBanners->fetch()) {
             $aAd = $doBanners->toArray();
             // Add the name of the ad to the report
             $emailBody .= sprintf($strBannerPrint, $strBanner) . ' ';
             $emailBody .= strip_tags(phpAds_buildBannerName($aAd['bannerid'], $aAd['description'], $aAd['alt'])) . "\n";
             // If the ad has a URL, add the URL the add is linked to to the report
             if (!empty($aAd['url'])) {
                 $emailBody .= '  ' . $strLinkedTo . ': ' . $aAd['url'] . "\n";
             }
             $emailBody .= "\n";
         }
     }
     return $emailBody;
 }
开发者ID:ballistiq,项目名称:revive-adserver,代码行数:49,代码来源:Email.php

示例11: processForm

function processForm($aZone, $form, $oComponent = null)
{
    $aFields = $form->exportValues();
    if (empty($aFields['zoneid'])) {
        return;
    }
    $doZones = OA_Dal::factoryDO('zones');
    $doZones->get($aFields['zoneid']);
    // Determine chain
    if ($aFields['chaintype'] == '1' && $aFields['chainzone'] != '') {
        $chain = 'zone:' . $aFields['chainzone'];
    } else {
        $chain = '';
    }
    $doZones->chain = $chain;
    if (!isset($aFields['prepend'])) {
        $aFields['prepend'] = '';
    }
    $aFields['prepend'] = MAX_commonGetValueUnslashed('prepend');
    $doZones->prepend = $aFields['prepend'];
    // Do not save append until not finished with zone appending, if present
    if (!empty($aFields['appendsave'])) {
        if (!isset($aFields['append'])) {
            $aFields['append'] = '';
        }
        if (!isset($aFields['appendtype'])) {
            $aFields['appendtype'] = phpAds_ZoneAppendZone;
        }
        $aFields['append'] = MAX_commonGetValueUnslashed('append');
        $doZones->append = $aFields['append'];
        $doZones->appendtype = $aFields['appendtype'];
    }
    if (isset($aFields['forceappend'])) {
        $doZones->forceappend = $aFields['forceappend'];
    }
    $block = _initCappingVariables($aFields['time'], $aFields['capping'], $aFields['session_capping']);
    // Set adselection PCI if required
    if (isset($aFields['ext_adselection'])) {
        $doZones->ext_adselection = $aFields['ext_adselection'] == 'none' ? OX_DATAOBJECT_NULL : $aFields['ext_adselection'];
    }
    $doZones->block = $block;
    $doZones->capping = $aFields['capping'];
    $doZones->session_capping = $aFields['session_capping'];
    if ($aFields['show_capped_no_cookie'] != 1) {
        $aFields['show_capped_no_cookie'] = 0;
    }
    $doZones->show_capped_no_cookie = $aFields['show_capped_no_cookie'];
    $doZones->update();
    // Queue confirmation message
    $translation = new OX_Translation();
    $translated_message = $translation->translate($GLOBALS['strZoneAdvancedHasBeenUpdated'], array(MAX::constructURL(MAX_URL_ADMIN, 'zone-edit.php?affiliateid=' . $aFields['affiliateid'] . '&zoneid=' . $aFields['zoneid']), htmlspecialchars($doZones->zonename)));
    OA_Admin_UI::queueMessage($translated_message, 'local', 'confirm', 0);
    // Rebuild Cache
    // require_once MAX_PATH . '/lib/max/deliverycache/cache-'.$conf['delivery']['cache'].'.inc.php';
    // phpAds_cacheDelete('what=zone:'.$zoneid);
    $oUI = OA_Admin_UI::getInstance();
    OX_Admin_Redirect::redirect("zone-advanced.php?affiliateid=" . $aFields['affiliateid'] . "&zoneid=" . $aFields['zoneid']);
}
开发者ID:ballistiq,项目名称:revive-adserver,代码行数:58,代码来源:zone-advanced.php

示例12: OA_Admin_Template

                                         }
                                     } else {
                                         if ('settings' == $action) {
                                             require_once LIB_PATH . '/Admin/Redirect.php';
                                             OX_Admin_Redirect::redirect("plugin-settings.php?group={$group}&parent={$parent}");
                                         } else {
                                             if ('preferences' == $action) {
                                                 require_once LIB_PATH . '/Admin/Redirect.php';
                                                 OX_Admin_Redirect::redirect("plugin-preferences.php?group={$group}&parent={$parent}");
                                             } else {
                                                 if (array_key_exists('checkdb', $_GET)) {
                                                     $aInfo = $oComponentGroupManager->getComponentGroupInfo($_GET['checkdb']);
                                                     $aSchema = $oComponentGroupManager->checkDatabase($_GET['checkdb'], $aInfo);
                                                     $oTpl = new OA_Admin_Template('plugin-group-index.html');
                                                     $oTpl->assign('parent', $_GET['parent']);
                                                     $oTpl->assign('parenturl', MAX::constructURL(MAX_URL_ADMIN, "plugin-index.php?info={$_GET['parent']}&package=true"));
                                                     $oTpl->assign('aHeader', $aInfo);
                                                     $oTpl->assign('aPluginDB', $aSchema);
                                                 }
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
 }
开发者ID:villos,项目名称:tree_admin,代码行数:31,代码来源:plugin-index.php

示例13: OX_Translation

}
/*-------------------------------------------------------*/
/* Main code                                             */
/*-------------------------------------------------------*/
if (!empty($campaignid)) {
    if (!empty($duplicate)) {
        // Duplicate the campaign
        $doCampaigns = OA_Dal::factoryDO('campaigns');
        $doCampaigns->get($campaignid);
        $oldName = $doCampaigns->campaignname;
        $newCampaignId = $doCampaigns->duplicate();
        if ($newCampaignId) {
            // Queue confirmation message
            $newName = $doCampaigns->campaignname;
            $translation = new OX_Translation();
            $translated_message = $translation->translate($GLOBALS['strCampaignHasBeenDuplicated'], array(MAX::constructURL(MAX_URL_ADMIN, "campaign-edit.php?clientid={$clientid}&campaignid={$campaignid}"), htmlspecialchars($oldName), MAX::constructURL(MAX_URL_ADMIN, "campaign-edit.php?clientid={$clientid}&campaignid={$newCampaignId}"), htmlspecialchars($newName)));
            OA_Admin_UI::queueMessage($translated_message, 'local', 'confirm', 0);
            Header("Location: {$returnurl}?clientid={$clientid}&campaignid={$newCampaignId}");
            exit;
        } else {
            phpAds_sqlDie();
        }
    } else {
        if (!empty($newclientid)) {
            /*-------------------------------------------------------*/
            /* Restore cache of $node_array, if it exists            */
            /*-------------------------------------------------------*/
            if (isset($session['prefs']['advertiser-index.php']['nodes'])) {
                $node_array = $session['prefs']['advertiser-index.php']['nodes'];
            }
            /*-------------------------------------------------------*/
开发者ID:Spark-Eleven,项目名称:revive-adserver,代码行数:31,代码来源:campaign-modify.php

示例14: array

/*-------------------------------------------------------*/
if (!empty($action)) {
    if (empty($acl)) {
        $acl = array();
    }
    $acl = MAX_AclAdjust($acl, $action);
} elseif (!empty($submit)) {
    $acl = isset($acl) ? $acl : array();
    // Only save when inputs are valid
    if (OX_AclCheckInputsFields($acl, $pageName) === true) {
        if (MAX_AclSave($acl, $aEntities)) {
            // Queue confirmation message
            $doChannel = OA_Dal::factoryDO('channel');
            $doChannel->get($channelid);
            $translation = new OX_Translation();
            $translated_message = $translation->translate($GLOBALS['strChannelAclHasBeenUpdated'], array(MAX::constructURL(MAX_URL_ADMIN, "channel-edit.php?" . (!empty($affiliateid) ? "affiliateid={$affiliateid}&" : "") . "channelid={$channelid}"), htmlspecialchars($doChannel->name)));
            OA_Admin_UI::queueMessage($translated_message, 'local', 'confirm', 0);
            // Redirect
            if (!empty($affiliateid)) {
                header("Location: channel-acl.php?affiliateid={$affiliateid}&channelid={$channelid}");
            } else {
                header("Location: channel-acl.php?channelid={$channelid}");
            }
            exit;
        }
    }
}
/*-------------------------------------------------------*/
/* HTML framework                                        */
/*-------------------------------------------------------*/
MAX_displayNavigationChannel($pageName, $aOtherChannels, $aEntities);
开发者ID:Spark-Eleven,项目名称:revive-adserver,代码行数:31,代码来源:channel-acl.php

示例15: display

 /**
  * A method to launch and display the widget
  *
  * @param array $aParams The parameters array, usually $_REQUEST
  */
 function display()
 {
     $conf = $GLOBALS['_MAX']['CONF'];
     if (!$conf['audit']['enabled']) {
         $this->oTpl->assign('screen', 'disabled');
         $this->oTpl->assign('siteTitle', $GLOBALS['strCampaignAuditTrailSetup']);
         $this->oTpl->assign('siteUrl', MAX::constructUrl(MAX_URL_ADMIN, 'account-settings-debug.php'));
     } else {
         $oCache = new OA_Cache('campaignOverview', 'Widgets');
         $aCache = $oCache->load(true);
         $aCampaign = array();
         if (isset($aCache['maxItems'])) {
             if (OA_Permission::isAccount(OA_ACCOUNT_ADMIN)) {
                 foreach ($aCache['aAccounts'] as $aActions) {
                     foreach ($aActions as $aAction) {
                         $aCampaign[$aAction['auditid']] = $aAction;
                     }
                 }
             } else {
                 $aAccountsId = OA_Permission::getOwnedAccounts(OA_Permission::getAccountId());
                 foreach ($aAccountsId as $accountId) {
                     if (isset($aCache['aAccounts'][$accountId])) {
                         foreach ($aCache['aAccounts'][$accountId] as $aAction) {
                             $aCampaign[$aAction['auditid']] = $aAction;
                         }
                     }
                 }
             }
             krsort($aCampaign);
             $aCampaign = array_slice($aCampaign, 0, $aCache['maxItems']);
         }
         if (count($aCampaign)) {
             $aActionMap = array('added' => $GLOBALS['strCampaignStatusAdded'], 'started' => $GLOBALS['strCampaignStatusStarted'], 'restarted' => $GLOBALS['strCampaignStatusRestarted'], 'completed' => $GLOBALS['strCampaignStatusExpired'], 'paused' => $GLOBALS['strCampaignStatusPaused'], 'deleted' => $GLOBALS['strCampaignStatusDeleted']);
             foreach ($aCampaign as $k => $v) {
                 if (isset($aActionMap[$v['action']])) {
                     $aCampaign[$k]['actionDesc'] = $aActionMap[$v['action']];
                 }
             }
         } else {
             // Check if the account has any campaign in its realm
             $doCampaigns = OA_Dal::factoryDO('campaigns');
             if (!empty($aParam['account_id'])) {
                 $doClients = OA_Dal::factoryDO('clients');
                 $doAgency = OA_Dal::factoryDO('agency');
                 $doAgency->account_id = $aParam['account_id'];
                 $doClients->joinAdd($doAgency);
                 $doCampaigns->joinAdd($doClients);
             }
             $doCampaigns->limit(1);
             $this->oTpl->assign('hasCampaigns', $doCampaigns->count());
             if (OA_Permission::isAccount(OA_ACCOUNT_ADMIN)) {
                 $this->oTpl->assign('isAdmin', true);
             }
         }
         $this->oTpl->assign('screen', 'enabled');
         $this->oTpl->assign('aCampaign', $aCampaign);
         $this->oTpl->assign('siteUrl', MAX::constructURL(MAX_URL_ADMIN, 'advertiser-campaigns.php'));
         $this->oTpl->assign('baseUrl', MAX::constructURL(MAX_URL_ADMIN, 'campaign-edit.php'));
     }
     $this->oTpl->display();
 }
开发者ID:Jaree,项目名称:revive-adserver,代码行数:66,代码来源:CampaignOverview.php


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