Services_Ebay
[ class tree: Services_Ebay ] [ index: Services_Ebay ] [ all elements ]

Source for file GetCrossPromotions.php

Documentation is available at GetCrossPromotions.php

  1. <?PHP
  2. /**
  3.  * Get cross promotions for an items
  4.  *
  5.  * $Id: GetCrossPromotions.php,v 1.1 2004/10/28 17:14:53 schst Exp $
  6.  *
  7.  * @package Services_Ebay
  8.  * @author  Stephan Schmidt <schst@php.net>
  9.  * @link    http://developer.ebay.com/DevZone/docs/API_Doc/Functions/GetCrossPromotions/GetCrossPromotions.htm
  10.  */
  11. {
  12.    /**
  13.     * verb of the API call
  14.     *
  15.     * @var  string 
  16.     */
  17.     protected $verb = 'GetCrossPromotions';
  18.  
  19.    /**
  20.     * arguments of the call
  21.     *
  22.     * @var  array 
  23.     */
  24.     protected $args = array(
  25.                             'PromotionMethod' => 'CrossSell'
  26.                         );
  27.    /**
  28.     * parameter map that is used, when scalar parameters are passed
  29.     *
  30.     * @var  array 
  31.     */
  32.     protected $paramMap = array(
  33.                                  'ItemId',
  34.                                  'PromotionMethod',
  35.                                  'PromotionViewMode'
  36.                                 );
  37.    /**
  38.     * make the API call
  39.     *
  40.     * @param    object Services_Ebay_Session 
  41.     * @return   string 
  42.     */
  43.     public function call(Services_Ebay_Session $session)
  44.     {
  45.         $bak $this->args;
  46.         $this->args['Context'= array();
  47.         foreach ($this->paramMap as $param{
  48.             if (!isset($this->args[$param])) {
  49.                 continue;
  50.             }
  51.             $this->args['Context'][$param$this->args[$param];
  52.             unset$this->args[$param);
  53.         }
  54.         
  55.         $return = parent::call($session);
  56.         $this->args = $bak;
  57.  
  58.         return $return['CrossPromotions'];
  59.     }
  60. }
  61. ?>

Documentation generated on Mon, 11 Mar 2019 13:58:46 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.