當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Am_HttpRequest::__construct方法代碼示例

本文整理匯總了PHP中Am_HttpRequest::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP Am_HttpRequest::__construct方法的具體用法?PHP Am_HttpRequest::__construct怎麽用?PHP Am_HttpRequest::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Am_HttpRequest的用法示例。


在下文中一共展示了Am_HttpRequest::__construct方法的11個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: __construct

 public function __construct($api_key)
 {
     $this->api_key = $api_key;
     parent::__construct();
     $this->setMethod(self::METHOD_POST);
     $this->setUrl($this->endpoint);
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:7,代碼來源:get-response.php

示例2: __construct

 public function __construct(Am_Paysystem_Abstract $plugin)
 {
     $this->plugin = $plugin;
     $cert_file = APPLICATION_PATH . '/configs/cert_key_pem.txt';
     if (is_file($cert_file) && is_readable($cert_file)) {
         $this->use_cert = true;
     }
     if (!$this->use_cert) {
         $url = $this->plugin->getConfig('testing') ? self::SANDBOX_URL : self::LIVE_URL;
     } else {
         $url = $this->plugin->getConfig('testing') ? self::CERT_SANDBOX_URL : self::CERT_LIVE_URL;
     }
     parent::__construct($url, self::METHOD_POST);
     if ($adapter = $this->plugin->createHttpRequest()->getConfig('adapter')) {
         $this->setConfig('adapter', $adapter);
     }
     // Check certificate file.
     if ($this->use_cert) {
         $this->setConfig('ssl_local_cert', $cert_file);
     }
     // Check certificate file.
     $ca_file = APPLICATION_PATH . "/configs/api_cert_chain.crt";
     if ($this->use_cert && is_file($ca_file) && is_readable($ca_file)) {
         $this->setConfig('ssl_cafile', $cert_file);
     }
     if (!$this->use_cert) {
         $this->addPostParameter('SIGNATURE', $this->plugin->getConfig('api_signature'));
     }
     $this->addPostParameter('VERSION', '63.0')->addPostParameter('BUTTONSOURCE', 'CgiCentral.aMemberPro')->addPostParameter('USER', $this->plugin->getConfig('api_username'))->addPostParameter('PWD', $this->plugin->getConfig('api_password'));
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:30,代碼來源:PaypalApiRequest.php

示例3: __construct

 public function __construct(Am_Paysystem_Abstract $plugin)
 {
     $this->plugin = $plugin;
     parent::__construct($this->plugin->getConfig('testing') ? self::SANDBOX_URL : self::LIVE_URL, self::METHOD_POST);
     if ($adapter = $this->plugin->createHttpRequest()->getConfig('adapter')) {
         $this->setConfig('adapter', $adapter);
     }
     $this->addPostParameter('VERSION', '63.0')->addPostParameter('SIGNATURE', $this->plugin->getConfig('api_signature'))->addPostParameter('USER', $this->plugin->getConfig('api_username'))->addPostParameter('PWD', $this->plugin->getConfig('api_password'));
 }
開發者ID:subashemphasize,項目名稱:test_site,代碼行數:9,代碼來源:PaypalApiRequest.php

示例4: __construct

 public function __construct($plugin, $requestType)
 {
     $this->plugin = $plugin;
     $this->requestType = $requestType;
     parent::__construct();
     $this->setUrl($this->plugin->getConfig('testMode') ? Am_Paysystem_Intuit::URL_TEST : Am_Paysystem_Intuit::URL_LIVE);
     $this->setMethod(Am_Request::METHOD_POST);
     $this->setHeader('Content-type', 'application/x-qbmsxml');
 }
開發者ID:alexanderTsig,項目名稱:arabic,代碼行數:9,代碼來源:intuit.php

示例5: __construct

 public function __construct($url, $debug = false)
 {
     parent::__construct();
     $this->setMethod(self::METHOD_POST);
     $this->setHeader('Content-type: text/xml; charset=utf-8');
     $this->setUrl($url);
     $this->debuglog = $debug;
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:8,代碼來源:interspire.php

示例6: __construct

 public function __construct($xmlOut, $requestType, $debugMode = false)
 {
     $this->requestType = $requestType;
     $this->debugMode = $debugMode;
     parent::__construct(Am_Paysystem_PaymentExpress::URL, self::METHOD_POST);
     $this->setBody($xmlOut);
 }
開發者ID:alexanderTsig,項目名稱:arabic,代碼行數:7,代碼來源:payment-express.php

示例7: __construct

 public function __construct(Am_Newsletter_Plugin_Madmimi $plugin)
 {
     $this->plugin = $plugin;
     parent::__construct();
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:5,代碼來源:madmimi.php

示例8: __construct

 public function __construct(Am_Newsletter_Plugin_Icontact $plugin)
 {
     parent::__construct();
     if ($plugin->getConfig('testmode')) {
         $this->setLink($this->urlTest . '/icp/a/' . $plugin->getConfig('accountid') . '/c/' . $plugin->getConfig('clientfolderid'));
     } else {
         $this->setLink($this->urlWork . '/icp/a/' . $plugin->getConfig('accountid') . '/c/' . $plugin->getConfig('clientfolderid'));
     }
     $this->debugLog = $plugin->getConfig('debuglog');
     $this->setHeader(array('Accept: application/json', 'Content-Type: application/json', 'Api-Version: 2.0', 'Api-Username: ' . $plugin->getConfig('user'), 'Api-AppId: ' . $plugin->getConfig('apiappid'), 'Api-Password: ' . $plugin->getConfig('apipass')));
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:11,代碼來源:icontact.php

示例9: __construct

 public function __construct(Am_Newsletter_Plugin_Autoresponderpro $plugin)
 {
     $this->plugin = $plugin;
     parent::__construct();
     $this->setMethod(self::METHOD_POST);
     $this->setHeader('Content-type: text/xml; charset=utf-8');
     $this->setUrl($this->url);
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:8,代碼來源:autoresponderpro.php

示例10: __construct

 public function __construct($account_id, $auth_token)
 {
     $this->account_id = $account_id;
     $this->auth_token = $auth_token;
     parent::__construct();
 }
開發者ID:grlf,項目名稱:eyedock,代碼行數:6,代碼來源:maropost.php

示例11: __construct

 public function __construct(Am_Newsletter_Plugin_Sendgrid $plugin)
 {
     $this->plugin = $plugin;
     parent::__construct();
     $this->setMethod(self::METHOD_POST);
 }
開發者ID:alexanderTsig,項目名稱:arabic,代碼行數:6,代碼來源:sendgrid.php


注:本文中的Am_HttpRequest::__construct方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。