Initial COmmit...alr did some stuff lol

This commit is contained in:
2026-03-03 18:14:48 -06:00
commit 10789dce3c
161 changed files with 50150 additions and 0 deletions

74
form-process.php Normal file
View File

@@ -0,0 +1,74 @@
<?php
$errorMSG = "";
// FIRSTNAME
if (empty($_POST["fname"])) {
$errorMSG = "Full Name is required. ";
} else {
$fname = $_POST["fname"];
}
// LASTNAME
if (empty($_POST["lname"])) {
$errorMSG = "Full Name is required. ";
} else {
$lname = $_POST["lname"];
}
// EMAIL
if (empty($_POST["email"])) {
$errorMSG .= "Email is required. ";
} else {
$email = $_POST["email"];
}
// PHONE
if (empty($_POST["phone"])) {
$errorMSG .= "Phone is required. ";
} else {
$phone = $_POST["phone"];
}
// MESSAGE
if (empty($_POST["message"])) {
$errorMSG .= "Message is required. ";
} else {
$message = $_POST["message"];
}
$subject = 'Contact Inquiry from Physiocare Website';
//$EmailTo = "info@yourdomain.com"; // Replace with your email.
$EmailTo = "awaikentechnology@gmail.com";
// prepare email body text
$Body = "";
$Body .= "Name: ";
$Body .= $fname." ".$lname;
$Body .= "\n";
$Body .= "Email: ";
$Body .= $email;
$Body .= "\n";
$Body .= "Phone: ";
$Body .= $phone;
$Body .= "\n";
$Body .= "Message: ";
$Body .= $message;
$Body .= "\n";
// send email
$success = @mail($EmailTo, $subject, $Body, "From:".$email);
// redirect to success page
if ($success && $errorMSG == ""){
echo "success";
}else{
if($errorMSG == ""){
echo "Something went wrong :(";
} else {
echo $errorMSG;
}
}
?>