Advertisement
rodro1

Curl example post sms gateway

Jul 30th, 2021
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. $curl = curl_init();
  2.  
  3. curl_setopt_array($curl, array(
  4. CURLOPT_URL => $url,
  5. CURLOPT_RETURNTRANSFER => true,
  6. CURLOPT_ENCODING => "",
  7. CURLOPT_MAXREDIRS => 10,
  8. CURLOPT_TIMEOUT => 0,
  9. CURLOPT_FOLLOWLOCATION => true,
  10. CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  11. // CURLOPT_CUSTOMREQUEST => "POST",
  12. ));
  13.  
  14. $response = curl_exec($curl);
  15.  
  16. curl_close($curl);
  17. return $response;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement