thank you page and mail template

This commit is contained in:
2022-02-25 12:06:26 +00:00
parent f63ab1c930
commit ab1f9d9bf5
21 changed files with 912 additions and 144 deletions

View File

@@ -255,6 +255,7 @@ include("_navbar.php");
<!-- Input -->
<input class="form-control" id="phn" type="number" name="telephone"
placeholder="Enter your Contact number" required>
<p id="phnError" style="color: red; display: none;">Enter a valid phone number</p>
</div>
</div>
</div>
@@ -332,10 +333,13 @@ include("_navbar.php");
warning.style.display = "block";
} else {
var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/;
var mobile = /^\d{10}$/;
if (reg.test(email) == false) {
emailError.style.display = "block";
} else {
}else if (mobile.test(phn) == false) {
phnError.style.display = "block";
} else {
emailError.style.display = "none";
warning.style.display = "none";
let formData = new FormData();
@@ -422,13 +426,16 @@ include("_navbar.php");
formData.append("reciever", sendEmail);
formData.append("sender", "IIMTT");
formData.append("senderMail", "enquiry@iimtt.org");
formData.append("subject", "Welcome to IIMTT");
formData.append(
"message",
"<html><body><p>Welcome " +
name +
" to IIMTT Hanoi.<br>Thank you for contacting us. <br> We will get back to you shortly. In the meanwhile please do check out our website for more information. click <a href='https://iimtt.org'>here</a><br>Thank you<br>-Team IIMTT. </p></body></html>"
);
formData.append("subject", "Thank you for contacting IIMTT.");
formData.append(
"message",
'<html><body style="background-color:#f5f8f5;padding:16px;"><div style="text-align:center"><a href="#"><img style="width:150px;" src="https://iimtt.org/assets/img/iimtt-footer-logo.png"></a></div>'+
'<div><b style="font-size:20px">Hi '+name+'</b><p>Thank you for reaching International Institute of Montessori Teacher Training.</p>'+
'<p>IIMTT was established to help meet the growing demand for Montessori teachers in India and abroad.Our course equips participants to educate children in the Montessori Method, at the pre-primary level anywhere in the world.</p>'+
'<p>Our representative will get in touch with you soon!</p></div><div style="text-align:center"><a style="background-color:#f7a325;color:black;padding:4px 6px;text-decoration:none" class="btn btn-secondary btn-form display-4" href="https://drive.google.com/file/d/11JW1i7annvdjF6rG5vwSFBjIBaMDfAqZ/view?usp=sharing">Download Brochure</a></div><p>Thanks<br>Team IIMTT</p>'+
'<div style="text-align:center"><p><b>Follow us</b><br><a href="#"><div style="display:none"><img style="width:1px;margin-right:10px;" src="https://cdn3.iconfinder.com/data/icons/free-social-icons/67/linkedin_circle_color-512.png" alt="Logo"></div></a><a href="https://www.facebook.com/IIMTT/" target="_blank"><div style="display:none"<img style="width:26px;margin-right:10px" src="https://cdn3.iconfinder.com/data/icons/capsocial-round/500/facebook-1024.png" alt="Logo"></div></a><a href="https://www.facebook.com/IIMTT/" target="_blank"><img style="width:26px;margin-right:10px" src="https://cdn3.iconfinder.com/data/icons/capsocial-round/500/facebook-1024.png" alt="Logo"></a><a href="https://www.instagram.com/iimtt.corporate/" target="_blank"><img style="width:26px;margin-right:10px" src="https://cdn2.iconfinder.com/data/icons/social-icons-33/128/Instagram-512.png" alt="Logo"></a><a href="https://twitter.com/iimtt_corporate" target="_blank"><img style="width:26px;margin-right:10px" src="https://cdn2.iconfinder.com/data/icons/social-media-2285/512/1_Twitter2_colored_svg-256.png" alt="Logo"></a>'+
'<a href="https://www.linkedin.com/showcase/international-institute-of-montessori-teacher-training/" target="_blank"><img style="width:30px;" src="https://cdn3.iconfinder.com/data/icons/free-social-icons/67/linkedin_circle_color-512.png" alt="Logo"></a><br><hr><b>International Institute of Montessori Teacher Training</b><br>Kemp House 160 City Road, London, Ec1v2nx<br>© 2021 IIMTT All rights reserved.</p></div></body></html>'
);
fetch("https://mailapi.teenybeans.in/", {
method: "POST",
body: formData