title: Zabbix login with php
body: <p>I have written a simple test page which logins to Zabbix server using the API Provided in <a href="https://github.com/confirm-it-solutions/PhpZabbixApi/releases" rel="nofollow noreferrer">https://github.com/confirm-it-solutions/PhpZabbixApi/releases</a> </p>
  
  <p>Below is the code i have written.</p>
  
  <pre><code>    &lt;?php
  // load ZabbixApi
  require_once 'build/ZabbixApi.class.php';
  use ZabbixApi\ZabbixApi;
  
  try
  {
      // connect to Zabbix API
      $api = new ZabbixApi('http://xxx.xxx.xxx/zabbix/', 'credit', 'debit','','');
  
      /* ... do your stuff here ... */
  }
  catch(Exception $e)
  {
      echo"In Exception &lt;br/&gt;";
      // Exception in ZabbixApi catched
      echo $e-&gt;getMessage();
  }
  ?&gt;
  </code></pre>
  
  <p>and below is the error i am getting.
  "In Exception Could not decode JSON response"</p>
  
  <p>Thanks in advance.</p>