예제 #1
0
파일: amzecs.php 프로젝트: kostya1017/our
 function Amzecs()
 {
     $this->CI =& get_instance();
     $this->CI->load->database();
     $this->CI->config->load('db_tables');
     $db_tables = $this->CI->config->item('db_tables');
     $db_tables = $db_tables[$db_tables['environment']];
     $mysql_tables = $db_tables['mysql'];
     foreach ($mysql_tables as $name => $table) {
         $this->{'_table_' . $name} = $table;
     }
     $accessKey = $this->CI->config->item('amazon_ecs_access_key');
     $secretKey = $this->CI->config->item('amazon_ecs_secret_key');
     $countryCode = $this->CI->config->item('amazon_ecs_country');
     $associateTag = $this->CI->config->item('amazon_ecs_associate_tag');
     parent::__construct($accessKey, $secretKey, $countryCode, $associateTag);
     //require_once(dirname(BASEPATH).'/system/application/libraries/httpSockets.class.php');
     //we are not going to attempt to use PEAR...
     require_once 'HTTP/Request2.php';
     $this->cookies = array();
     $this->agents = array('Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)', 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)', 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1); Trident/5.0', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/25.0.1364.172 Safari/537.22', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.17 (KHTML, like Gecko) Version/6.0.2 Safari/536.26.17', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:19.0) Gecko/20100101 Firefox/19.0', 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en) AppleWebKit/522.11.3 (KHTML, like Gecko) Version/3.0 Safari/522.11.3', 'Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8) Gecko/20051107 Firefox/1.5', 'Opera/9.80 (Macintosh; Intel Mac OS X 10.8.2) Presto/2.12.388 Version/12.14', 'Opera/9.0 (Windows NT 5.0; U; en)');
     $this->warn_max = $this->CI->config->item('warn_max');
     $this->warn_minutes = $this->CI->config->item('warn_minutes');
     $this->warn_period = $this->CI->config->item('warn_period');
 }