sms_test.php 1.29 KB
<?php
$url = 'https://push3.maccesssmspush.com/servlet/com.aclwireless.pushconnectivity.listeners.TextListener?';
//$url = 'https://push3.maccesssmspush.com/servlet/com.aclwireless.pushconnectivity.listeners.TextListener?userId=hdfcbalrt&pass=hdfcbalrt25&appid=hdfcbalrt&subappid=hdfcbalrt&contenttype=1&to=8074030875&from=HDFCBK&text=manoj&selfid=true&alert=1&dlrreq=true&intflag=false';
	$inputArray = ['userId'=>'hdfcbalrt',"pass"=>'hdfcbalrt25',"appid"=>"hdfcbalrt","subappid"=>"hdfcbalrt","contenttype"=>"1","to"=>"8074030875","from"=>"HDFCBK","text"=>"Hi","selfid"=>"true","alert"=>"1","dlrreq"=>"true","intflag"=>"false"];
$payload = json_encode($inputArray);
		    $payload = json_encode($jsonBody);
		    $ch = curl_init();
		    curl_setopt($ch, CURLOPT_COOKIE, "");
		    curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
		    curl_setopt($ch, CURLOPT_URL, $url);
		   curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
		    curl_setopt($ch, CURLOPT_POST, 1);
		    curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
		   curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
		    curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type:application/json',
		        'AUTHORIZATIONKEY:' . $X_AUTH_T,
		        'X-EMAIL:' . $X_EMAIL_T, 'Cache-Control:no-cache'
		    ));
		    curl_exec($ch);
		    curl_close($ch);
?>