-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsendemail.php
48 lines (37 loc) · 1.28 KB
/
sendemail.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
<?php
$EmailFrom="info@mithr.io";
$EmailTo="whitelist@mithr.io";
$Subject="Email enviado desde el Formulario de Mithr.io, para anotarme en la WHITE LIST!";
$SubjectUser="Te registraste para recibir el AirDrop de Mithr! Felicitaciones!";
$Email=Trim(stripslashes($_POST['email']));
// simple way to validate the form
$ValidationOk=true;
if ($Email == "") $ValidationOk=false;
if (!$ValidationOk) {
echo "<meta http-equiv=\"refresh\" content=\"0;URL=error.html\">";
exit;
}
// preparing the body of the email
$Body="";
$Body.="Email: ";
$Body.=$Email;
$Body.="\n";
$Body_User="";
$Body_User.="Te anotaste correctamente para recibir el AirDrop de MITHR, desde el email: ";
$Body_User.=$Email;
$Body_User.="\n";
$Body_User.="FELICITACIONES! Te avisaremos cuando necesitemos tu Address Wallet de CARDANO para enviarte los Tokens.";
$Body_User.="\n";
$Body_User.="Salu2!, El equipo de Mithradir.";
$Body_User.="\n";
//sending the email now
$success=mail($EmailTo, $Subject, $Body,"From: <$EmailFrom>");
$success_dos=mail($Email, $SubjectUser, $Body_User,"From: <$EmailFrom>");
//redirect after mail send
if ($success) {
print "<meta http-equiv=\"refresh\" content=\"0;URL=send.html\">";
}
else {
print "<meta http-equiv=\"refresh\" content=\"0;URL=error.html\">";
}
?>