📁 File Manager
Editing:
/home/wedigitalindia/public_html/home-wedigitalindia/jopajifoods/enquiry.php
<?php session_start(); include 'admin/include/connection.php'; if(isset($_POST['submit'])){ date_default_timezone_set("Asia/Kolkata"); $enquiry_date = Date('Y-m-d'); $name = strip_tags(htmlspecialchars($_POST['name'])); $sub=strip_tags(htmlspecialchars($_POST['subject'])); $email = strip_tags(htmlspecialchars($_POST['email'])); $message = strip_tags(htmlspecialchars($_POST['message'])); $to = "info@jopajifoods.com"; // change this email to your // $subject = "$sub: $name"; $body = "You have received a new message from your website contact form.\n\n"."Here are the details:\nName: $name\nEmail:$email\nSubject:$sub\nMessage:$message"; $header = "From:$email"; //$header .= "Reply-To: $email"; if(mail("info@jopajifoods.com",$sub,$body,$header)) { $sql1 =mysqli_query($con,"INSERT INTO enquiry(name,email,subject,message,date) VALUES('$name','$email','$sub','$message','$enquiry_date')"); header("location:contact-us.php"); } http_response_code(500); } ?>
Save
Cancel