Skip to content

Instantly share code, notes, and snippets.

@phpfiddle
Created October 25, 2019 14:38
Show Gist options
  • Save phpfiddle/0cdd0c6353e269ecdc48a959cee70112 to your computer and use it in GitHub Desktop.
Save phpfiddle/0cdd0c6353e269ecdc48a959cee70112 to your computer and use it in GitHub Desktop.
[ Posted by Myeishvar ] This is an easyway to send unicode sms by www.Lifetimesms.com
<?php
$url = "http://admin.lifetimesms.com/plain";
$parameters = array("api_token" => "Your API token",
"api_secret" => "Your API secret",
"to" => "92xxxxxxxxxx",
"from" => "Brand",
"type" => "unicode",
"message" => "لائف ٹائم ایس ایم ایس"
);
$ch = curl_init();
$timeout = 30;
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $parameters);
curl_setopt($ch, CURLOPT_TIMEOUT, $timeout);
$response = curl_exec($ch);
curl_close($ch);
echo $response ;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment