Advertisement
Guest User

Untitled

a guest
Oct 9th, 2017
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. $cloud_url = "http(s)://client.sendsms.com/api/sendsms.aspx?";
  2. $gsm = $country_code . $contact;
  3.  
  4. $clould_pass=MD5($cloud_pass);
  5. $msg = urlencode(stripcslashes($message));
  6. $post_vars = "username=".$cloud_user."&pass=".$cloud_pass."&sender=".$sender."&smstext=".$msg."&isflash=0&gsm=".$gsm;
  7.  
  8. $ch = curl_init($cloud_url);
  9. curl_setopt($ch, CURLOPT_POST, 1);
  10. curl_setopt($ch, CURLOPT_POSTFIELDS,$post_vars);
  11. curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
  12. curl_setopt($ch, CURLOPT_HEADER, 0);
  13. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  14. $response = curl_exec($ch);
  15.  
  16. $err = curl_error($ch);
  17. curl_close($ch);
  18. if ($err) {
  19. echo "cURL Error #:" . $err;
  20. } else {
  21. echo $response;
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement