-
Notifications
You must be signed in to change notification settings - Fork 0
/
contact.php
35 lines (31 loc) · 1.38 KB
/
contact.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
$TITLE = "Contact Us -- Bookstore Inc";
require_once "lib/sanitizers_validators.php";
if ($_SERVER["REQUEST_METHOD"] === "POST") {
$name = $_POST["name"];
$email = $_POST["email"];
// WIP: Need to debug why mail is not being sent
echo mail($email, "Thanks for contacting {$name}", "Thank You {$name}, We will get to you shortly");
echo "Done";
die();
}
require_once "templates/header.html.php";
?>
<div id="content">
<link href="/assets/css/contact.css" rel="stylesheet" type="text/css" />
<div class="contact">
<form name="contact" method="POST" action="/contact.php">
<h1>Contact Us</h1><br>
<p>Enter Your Name</p><br>
<input type="text" name="name" placeholder="Enter Your Name" required><br><br>
<p>Enter your Email</p><br>
<input type="text" name="email" placeholder="Enter Your Email" required><br><br>
<P>Massage Body</P><br>
<textarea wrap="soft" cols="30" rows="10" placeholder="Enter Your Message" name="massage" required></textarea><br><br>
<br> <input type="submit" value="Submit" name="submit"><br><br>
<p>Help line-1800 000 123</p><br>
<p>Email Us: [email protected]</p>
</form>
</div>
</div> <!-- end of content -->
<?php require_once "templates/footer.html.php"; ?>