title: returning server response and display in the same page
body: <p>I have been trying to run this sript for weeks now.</p>
  
  <p>What I want is this to be sending data to the server shown there and return the server response but all I'm getting from the response is the url but the url is not executed it only getting displayed on the response var</p>
  
  <pre><code>&lt;?php
  class send
  {
  
      public $username;
      public $password;
      public $destination;
      public $sender;
      public $msg;
      public $type;
      public $dlr;
      public $url;
  
      function __construct()
      {
      }
  
      function send_sms(){
          $posturl = 'http://121.241.242.114:8080/bulksms/bulksms?';
          $number = $this-&gt;destination;
  
          $msg = urlencode($this-&gt;msg);
          $type='0';
          $dlr='1';
          $url='';
          $posturl = $posturl."source=".$this-&gt;sender."&amp;username=".$this-&gt;username."&amp;password=".$this-&gt;password."&amp;type=".$type."&amp;dlr=".$dlr."&amp;destination=".$number."&amp;message=".$msg;
          $ch = curl_init(); 
          curl_setopt($ch, CURLOPT_URL, $posturl); 
          curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); 
          curl_setopt($ch, CURLOPT_POST, true);
          $response = curl_exec($ch); 
          return $posturl;
      }
  
  }
  ?&gt;
  </code></pre>