<?php

function send_sms($destination,$message)
{
$pass = 'hubert321';

$url = 'http://103.242.119.152/vendorsms/pushsms.aspx';
		
		$fields = array(
		'user'      => 'Hubertozz',
		'password'      => $pass,
		'msisdn'    => $destination,
		'sid'    => 'HUBERT',
		'msg'    => $message,
		'fl'    => 0,
		'gwid'      => 2
		);
		
		//open connection
		$ch = curl_init();
		
		//set the url, number of POST vars, POST data
		curl_setopt($ch, CURLOPT_URL, $url);
		curl_setopt($ch, CURLOPT_POST, count($fields));
		curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($fields));
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
		
		//execute post
		$result = curl_exec($ch);

		$data = json_decode($result,true);

		//var_dump($result);
		// if ($result == "1") {
		// 	return 1;
		// }
		// else
		// {
		// 	return 0;
		// }

		//close connection
		curl_close($ch);
}

send_sms('9619056696','Hello');





?>	