Professional Documents
Culture Documents
How To Integrate SMS in PHP Form: Menu
How To Integrate SMS in PHP Form: Menu
Menu
Custom Search
250Mb
Need a Website Or Web Application Or Any Help In Code As Broadband
Per Your Budget, Contact Us: +91 9437911966 (Whatsapp)
index.php
process.php
index.php
<!DOCTYPE html>
<html>
<title>Form</title>
<body>
<form action="process.php" method="post">
Name:<input class="input" type="text"
placeholder="name" name="name"
required><br><br>
Email:<input class="input" type="email"
placeholder="email" name="email"
required><br><br>
Phone:<input class="input" type="text"
placeholder="phone" name="phone"
required><br><br>
<button type="submit" name="btn-
save">Submit</button>
</form>
</body>
</html>
process.php
<?php
//Your authentication key
$authKey = "abccccccccccfsssfresrr";
// mobiles numbers
$mobileNumber = $_POST["phone"];
//Define route
$route = "route=4";
//Prepare you post parameters
$postData = array(
'authkey' => $authKey,
'mobiles' => $mobileNumber,
'message' => $message,
'sender' => $senderId,
'route' => $route
);
//Put your sms provider api
$url="http://sms.com/api/sendhttp.php";
//get response
$output = curl_exec($ch);
curl_close($ch);
echo $output;
$url='localhost';
$username='admin';
$password='';
$conn=mysqli_connect($url,$username,$password,"sms");
if(!$conn){
die('Could not Connect My Sql:' .mysql_error());
}
if(isset($_POST['btn-save']))
{
// variables for input data
$name = $_POST['name'];
$email = $_POST['email'];
$phone = $_POST['phone'];
// sql query for inserting data into database
}
?>
❮ Previous Next ❯
Follow Us