-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathcontact.php
108 lines (100 loc) · 4.57 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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
<?php
// +------------------------------------------------------------------------+
// | @author Olakunlevpn (Olakunlevpn)
// | @author_url 1: http://www.maylancer.cf
// | @author_url 2: https://codecanyon.net/user/gr0wthminds
// | @author_email: olakunlevpn@live.com
// +------------------------------------------------------------------------+
// | PonziPedia - Peer 2 Peer 50% ROI Donation System
// | Copyright (c) 2018 PonziPedia. All rights reserved.
// +------------------------------------------------------------------------+
require_once 'app/init.php';
?>
<?php echo View::make('header')->render() ?>
<section>
<div class="container">
<div class="row block">
<div class="col-lg-9">
<ul class="breadcrumb">
<li class="breadcrumb-item"><a href="./">Home</a></li>
<li class="breadcrumb-item">Contact Us</li>
</ul>
<h1>Contact <?php echo Config::get('app.name'); ?></h1>
<p class="lead"><?php echo Config::get('app.name'); ?> support is here to help. Learn more about popular topics and find resources that will help you with all of your <?php echo Config::get('app.name'); ?> services.</p>
</div>
</div>
<?php
if (isset($_POST['sendMail'])) {
$email = $_POST['email'];
$departmant = $_POST['support'];
$subject = $_POST['subject'];
$message = $_POST['message'];
if ($departmant == "NULL") {
echo '<div id="top-alert" class="alert alert-danger" role="alert" style="
padding-top: 50px !important;
padding-bottom: 50px;font-size: 30px;
">
<button type="button" class="close"><a href="contact.php" class="btn btn-danger btn-sm">Try again</a></button>
<strong>OOPS!</strong> You need to select the suport department, please Try again!
</div>';
}
else{
$to = Config::get('app.webmail');
$Contactmessage = 'I need help from your '.$subject.' department below is my request<br><br>'.$message;
$header ="From: <".Config::get('app.name').">\r\n" .
"Reply-To: ".Config::get('app.name')."\r\n";
$header .= "MIME-Version: 1.0\r\n";
$header .= "Content-Type: text/html; charset=ISO-8859-1\r\n";
// if(mail($to,$subject,$Contactmessage,$header)){
echo '<div id="top-alert" class="alert alert-success" role="alert" style="
padding-top: 50px !important;
padding-bottom: 50px;font-size: 30px;
">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Message Sent!</strong>Your support message has been submitted successfully. Respond time is approximately 1 hour or less.
</div>';
//}
//else {
// echo '<div id="top-alert" class="alert alert-danger" role="alert">
// <button type="button" class="close" data-dismiss="alert">×</button>
// <strong>Sending Failed</strong> Error while sending your message to the support system, please Try again Later!
// </div>';
//}
}
}
else{?>
<div class="col-md-9">
<form method="POSt" action="">
<div class="form-group">
<label>Email Address</label>
<input type="email" name="email" class="form-control" placeholder="your email address" required>
</div>
<div class="form-group">
<label>Department </label>
<select class="c-select" class="form-control" name="support">
<option value="NULL" selected>Please choose support departmant</option>
<option value="customercare">Customar care</option>
<option value="marginteam">Margin Team</option>
<option value="Technical">Technical Department</option>
<option value="apirequest">API Request</option>
<option value="bugreport">Bug Report</option>
</select>
</div>
<div class="form-group">
<label>Subject</label>
<input type="text" name="subject" class="form-control" class="Your subject here" required>
</div>
<div class="form-group">
<label>Message</label>
<textarea type="text" name="message" class="form-control" class="Your message here" style="margin-top: 0px; margin-bottom: 0px; height: 170px;"></textarea>
</div>
<div class="form-group">
<input type="submit" name="sendMail" class="btn btn-primary btn-lg" value="Send Message" >
</div>
</form>
</div>
<?php }?>
</div>
</div>
</section>
<?php echo View::make('footer')->render() ?>