title: PHP Script not able to make Http request
body: <p>I have writtten this script in php to make a http request to <a href="http://ubaid.tk/sms/sms.aspx" rel="nofollow">http://ubaid.tk/sms/sms.aspx</a></p>
  
  <p>Here's the script-</p>
  
  <pre><code>    &lt;?php
  $connection_url = sprintf('http://ubaid.tk/sms/sms.aspx?uid=8149744569&amp;pwd=passmsg=%s&amp;phone=%s&amp;provider=way2sms', $_REQUEST['message'], $_REQUEST['mobileno.']);
  $ch = curl_init($connection_url);
  curl_setopt($ch, CURLOPT_POST, 1); 
  curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); // Return the result
  curl_setopt($ch, CURLOPT_COOKIEJAR, '/tmp/cookies.txt');
  curl_setopt($ch, CURLOPT_COOKIEFILE, '/tmp/cookies.txt');
  $data = curl_exec($ch); // Run the request
  // Display the result    
  echo "&lt;pre&gt;";
  print_r($data); /* result of SMS API call*/
  echo '&lt;/pre&gt;';
  ?&gt;
  </code></pre>
  
  <p>And I need this script to send a http request as <a href="http://ubaid.tk/sms/sms.aspx/uid=814974&amp;pwd=pass&amp;msg=" rel="nofollow">http://ubaid.tk/sms/sms.aspx/uid=814974&amp;pwd=pass&amp;msg=</a>$_REQUEST['message']&amp;phone=$_REQUEST['mobileno.']&amp;provider=way2sms</p>
  
  <p>The variables replaced and get back the response which the request gets and print it as it is. I have modified this script along with the code because I m still not able to get the correct output with it.</p>
  
  <p>I need to convert it to POST request what more modifications do I need to do?</p>