function sms_send() { $url = "http://bulksmsbd.net/api/smsapi?api_key=spz6JXwoCEfWPzcWBSZ9&type=text&number=Receiver&senderid=Random&message=TestSMS"; $api_key = "spz6JXwoCEfWPzcWBSZ9"; $senderid = "Random"; $number = "8801234567890"; $message = "[otp] is your OTP to confirm your phone no at BeeeBazar.com . Thanks for shopping. Stay with us."; $data = [ "api_key" => $api_key, "senderid" => $senderid, "number" => $number, "message" => $message ]; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); $response = curl_exec($ch); curl_close($ch); return $response; }