title: Razor pay integration in CI
body: <p>I am trying to integrate Razorpay paymentgetway in my webapplication which i am building in CI( codeigniter frame work ) with REST Controller .</p>
  
  <p>I used Razorpay reference code  snippet but it is showing error in "USE" Key word.</p>
  
  An uncaught Exception was encountered
  
  <p>Type: ParseError</p>
  
  <p>Message: syntax error, unexpected 'use' (T_USE)</p>
  
  <p>Filename: /var/www/html/...../...../,,,,/api/......php</p>
  
  <p>My code is as follow  which i am using is given below in PHP CI controller</p>
  
  <pre><code>class Manage_Po extends REST_Controller {
  
      function __construct() {
  
          require_once (APPPATH . '../assets/razorpay-php/Razorpay.php');
  
          use Razorpay\Api\Api;
  
          }
  </code></pre>
  
  <p>public function paymentrazor($dataPaytoken)
      {</p>
  
  <pre><code>     $api = new Api('rzp_test_oP14587HtL3lOEov4scw2', 'PdzPtvjZhku2210pHVQytsds44w7Fu');
  
      if (isset($dataPaytoken['PayToken']) === false) {
          die("Payment id not provided");
      }
  
      $id = $dataPaytoken['PayToken'] ;
  
      echo json_encode($payment-&gt;toArray());
  }
  </code></pre>
  
  <p>function payorder_post() {</p>
  
  <pre><code>$data=$this-&gt;input-&gt;post();
  
  
  if($data['status'] == 'true'){
      $this-&gt;paymentrazor($data['PayToken']);
  }
  </code></pre>
  
  <p>}</p>
  
  <p>}</p>