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


PHP Admin_DA::getVariables方法代码示例

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


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

示例1: testGetVariables

 function testGetVariables()
 {
     $variableId = Admin_DA::addVariable(array('trackerid' => rand(1, 999), 'name' => 'foo', 'description' => 'bar', 'datatype' => 'string', 'purpose' => 'basket_value'));
     $this->assertTrue(is_int($variableId));
     $retVar = Admin_DA::getVariables(array('variableid' => $variableId));
     $this->assertTrue(is_array($retVar[$variableId]));
 }
开发者ID:ballistiq,项目名称:revive-adserver,代码行数:7,代码来源:AdminDA.dal.test.php

示例2: _generateTrackerImageBeacon

 function _generateTrackerImageBeacon($trackerId)
 {
     $conf = $GLOBALS['_MAX']['CONF'];
     $variables = Admin_DA::getVariables(array('trackerid' => $trackerId), true);
     $beacon = "<div id='m3_tracker_{$trackerId}' style='position: absolute; left: 0px; top: 0px; visibility: hidden;'>";
     $beacon .= "<img src='" . MAX_commonConstructDeliveryUrl($conf['file']['conversion']) . "?trackerid={$trackerId}";
     foreach ($variables as $variable) {
         $beacon .= "&amp;{$variable['name']}=%%" . strtoupper($variable['name']) . "_VALUE%%";
     }
     $beacon .= "&amp;cb=%%RANDOM_NUMBER%%' width='0' height='0' alt='' /></div>";
     return $beacon;
 }
开发者ID:villos,项目名称:tree_admin,代码行数:12,代码来源:Invocation.php

示例3: phpAds_getTrackerDetails

    }
} else {
    // New tracker
    $doClients = OA_Dal::factoryDO('clients');
    if ($doClients->get($clientid)) {
        $client = $doClients->toArray();
    }
    if ($client) {
        $row['trackername'] = $client['clientname'] . ' - ';
    } else {
        $row["trackername"] = '';
    }
    $row["trackername"] .= $strDefault;
}
$trackerDetails = phpAds_getTrackerDetails($trackerid);
$trackerVariables = Admin_DA::getVariables(array('tracker_id' => $trackerid), true);
// Default to JS invocation if either appended HTML is found, or the tracker has variables
if (empty($invtype) && (!empty($trackerDetails['appendcode']) || !empty($trackerVariables))) {
    $invtype = 'js';
}
$maxInvocation = new MAX_Admin_Invocation();
if (isset($invtype) && $invtype == 'js') {
    $tracker_code = $maxInvocation->generateJavascriptTrackerCode($trackerid);
} else {
    $tracker_code = $maxInvocation->generateTrackerCode($trackerid);
}
/*-------------------------------------------------------*/
/* Main code                                             */
/*-------------------------------------------------------*/
$tabindex = 1;
// START CODE
开发者ID:villos,项目名称:tree_admin,代码行数:31,代码来源:tracker-invocation.php

示例4: _duplicateTracker

 function _duplicateTracker($aTracker, $checkUniqueNames = false)
 {
     $trackerId = $aTracker['tracker_id'];
     unset($aTracker['tracker_id']);
     if ($checkUniqueNames) {
         $aTrackers = Admin_DA::getTrackers(array('advertiser_id' => $aTracker['advertiser_id']));
         Admin_DA::_getUniqueName($aTracker, $aTrackers, @$GLOBALS['strCopy']);
     }
     // Massage to real field names
     Admin_DA::_switch($aTracker, 'advertiser_id', 'clientid');
     Admin_DA::_switch($aTracker, 'name', 'trackername');
     $newTrackerId = Admin_DA::addTracker($aTracker);
     if (PEAR::isError($newTrackerId)) {
         return PEAR::raiseError('failed to add tracker in ' . __FILE__ . ',' . __LINE__);
     }
     $aPlacementTrackers = Admin_DA::getPlacementTrackers(array('tracker_id' => $trackerId));
     foreach ($aPlacementTrackers as $aPlacementTracker) {
         $aPlacementTracker['tracker_id'] = $newTrackerId;
         Admin_DA::duplicatePlacementTracker($aPlacementTracker);
     }
     $aVariables = Admin_DA::getVariables(array('tracker_id' => $trackerId));
     foreach ($aVariables as $aVariable) {
         $aVariable['tracker_id'] = $newTrackerId;
         Admin_DA::duplicateVariable($aVariable);
     }
     return $newTrackerId;
 }
开发者ID:Apeplazas,项目名称:plazadelatecnologia,代码行数:27,代码来源:Admin_DA.php


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