예제 #1
0
 public function getDownloader()
 {
     if (is_null($this->_http)) {
         $this->_http = Mage_HTTP_Client::getInstance();
     }
     return $this->_http;
 }
예제 #2
0
파일: Loader.php 프로젝트: okite11/frames21
 /**
  * Factory for HTTP client
  * @param string/false $protocol  'curl'/'socket' or false for auto-detect
  * @return Mage_HTTP_Client/Mage_Connect_Loader_Ftp
  */
 public static function getInstance($protocol = '')
 {
     if ($protocol == 'ftp') {
         return new Mage_Connect_Loader_Ftp();
     } else {
         return Mage_HTTP_Client::getInstance();
     }
 }