Example #1
0
 public function __construct($iniFile)
 {
     $this->loadBaseMods();
     $this->loadIni($iniFile);
     $this->pdo = new lw\Pdo($this, $this->configArray['Pdo']);
     $this->curl = new \Curl\Curl();
     //Set this option because WAMP sucks
     $this->curl->setOpt(CURLOPT_SSL_VERIFYPEER, false);
     //Set this because all the returns are expecting JSON string, and Curl updated to do it automatically.
     $this->curl->setJsonDecoder(function ($response) {
         return $response;
     });
     $this->url = $this->configArray['Site']['url'];
     $this->title = $this->configArray['Site']['title'];
     Core::setApiKey($this->configArray['Site']['APIKEY']);
 }