HTML
xxxxxxxxxx
1
<hr class="wow fadeIn mt-5" data-wow-delay="0.4s">
2
3
<!--Section: Reservation-->
4
<section id="reservation" class="mb-5 pt-3 pb-5 wow fadeIn" data-wow-delay="0.2s">
5
6
<h5 class="text-center dark-grey-text text-uppercase font-weight-bold spacing my-5 py-4 wow fadeIn"
7
data-wow-delay="0.2s">
8
<strong>Reservation</strong>
9
10
11
</h5>
12
13
<!--Grid row-->
14
<div class="row">
15
16
<!--Grid column-->
17
<div class="col-lg-4 col-md-12">
18
<form class="contact-form" action="contactform.php" method="post">
19
<div class="input-group md-form form-sm form-3 pl-0">
20
<div class="input-group-prepend w-100">
21
<span class="input-group-text white black-text" id="basic-addon8">1</span>
22
<input type="text" name="name" class="form-control mt-0 blue-border rgba-white-strong" placeholder="Name"
23
aria-describedby="basic-addon8">
24
</div>
25
</div>
26
27
</div>
28
<!--Grid column-->
29
30
<!--Grid column-->
31
<div class="col-lg-4 col-md-6">
32
33
<div class="input-group md-form form-sm form-3 pl-0">
34
<div class="input-group-prepend w-100">
35
<span class="input-group-text white black-text" id="basic-addon9">2</span>
36
<input type="text" name="email" class="form-control mt-0 blue-border rgba-white-strong" placeholder="Email"
37
aria-describedby="basic-addon9">
38
</div>
39
</div>
40
41
</div>
42
<!--Grid column-->
43
44
<!--Grid column-->
45
<div class="col-lg-4 col-md-6">
46
47
<div class="input-group md-form form-sm form-3 pl-0">
48
<div class="input-group-prepend w-100">
49
<span class="input-group-text white black-text" id="basic-addon10">3</span>
50
<input type="text" name="date" class="form-control mt-0 blue-border rgba-white-strong" placeholder="Date"
51
aria-describedby="basic-addon10">
52
</div>
53
</div>
54
55
</div>
56
<!--Grid column-->
57
58
</div>
59
<!--Grid row-->
60
61
<!--Grid row-->
62
<div class="row mt-4">
63
64
<!--Grid column-->
65
<div class="col-lg-12 col-md-12">
66
67
<div class="form-group basic-textarea">
68
<label for="exampleFormControlTextarea2" class="font-small grey-text">Your message</label>
69
<textarea class="form-control" name="message" id="exampleFormControlTextarea2" rows="3"></textarea>
70
</div>
71
<button type="submit" name="submit" class="btn btn-info btn-sm font-weight-bold btn-outline-info waves-effect waves-light ml-0">
72
<strong>Book a room</strong>
73
</button>
74
75
</div>
76
<!--Grid column-->
77
78
</div>
79
<!--Grid row-->
80
81
</section>
82
CSS
1
1
JS
xxxxxxxxxx
1
<?php
2
3
if (isset ($_POST_POST['submit'])) {
4
$name = $_POST ['name'];
5
$subject = $_POST['exampleFormControlTextarea2'];
6
$mailfrom = $_POST['mail'];
7
$message = $_POST['exampleFormControlTextarea2'];
8
9
$mailTo = "mac@alohacircleislandtour.com";
10
$headers = "From: ".$mailFrom;
11
$txt = "You have received an e-mail from ".$name.".\n\n".$exampleFormControlTextarea2;
12
13
mail($mailTo, $subject, $txt, $headers);
14
header("Location: index.php?mailsend");
15
}
Console errors: 0