How to send SMS for subscriber using PHP
We need to get the message provider link then copy the below code. $host=$_SERVER['SERVER_NAME'];
$admin='info@'.$host;
$username= urlencode('username');//username
$password= urlencode('password');//pasword
$admin_phone=urlencode('mob.no');//mobile number
date_default_timezone_set("Asia/Kolkata");
$msg_provider='your message provider url';
$name=mysql_escape_string($_POST['name']);
$email=mysql_escape_string($_POST['email']);
$message=mysql_escape_string($_POST['message']);
$phone_message="Enquiry From : ".$name."\nPhone No : ".$phno."\nMessage : ".$message;
$msg1=urlencode($phone_message);
$msg_url = $msg_provider.'?user='.$username.'&pass='.$password.'&sender=BYPORT&phone='.$admin_phone.'&text='.$msg1.'&priority=ndnd&stype=normal';
$ch = curl_init($msg_url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$curl_scraped_page = curl_exec($ch);
curl_close($ch);