Skip to content

Commit

Permalink
Revert "solved issue #3092"
Browse files Browse the repository at this point in the history
  • Loading branch information
sailaja-adapa authored Oct 8, 2024
1 parent 7737a80 commit b8cd461
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3449,7 +3449,7 @@ <h3 style="text-align: center; color: #A30F17;">GET IN TOUCH</h3>

// You can add your form submission logic here (e.g., AJAX request)

alert('Your details has been saved successfully!'); // Success message
alert('Message sent and data saved locally!'); // Success message
});
});

Expand Down Expand Up @@ -3497,6 +3497,28 @@ <h3 style="text-align: center; color: #A30F17;">GET IN TOUCH</h3>
</section>

<script src="https://cdn.emailjs.com/dist/email.min.js"></script>
<script>
(function() {
emailjs.init("f6MOtkzVAVwSL9aru");
})();

const form = document.getElementById('contactForm');

form.addEventListener('submit', function(e) {
e.preventDefault();

emailjs.sendForm('service_id', 'template_id', form)
.then(function(response) {
console.log('SUCCESS!', response.status, response.text);
alert('Message successfully sent!');
window.location.reload(false);
}, function(error) {
console.error('FAILED...', error);
alert('Failed to send the message, please try again');
});
});
</script>



</article>
Expand Down

0 comments on commit b8cd461

Please sign in to comment.