adding in the basic testimonials and all
This commit is contained in:
Vendored
+19
-11
@@ -12,24 +12,32 @@ $(document).ready(function() {
|
||||
$('#email-form').submit(function(e) {
|
||||
e.preventDefault();
|
||||
|
||||
$('#popup')
|
||||
.text('Added to list! Thank you for joining!')
|
||||
.slideDown()
|
||||
.delay(4000)
|
||||
.slideUp();
|
||||
|
||||
$.ajax({
|
||||
url: 'https://ucharify-api.herokuapp.com/api/users/landing',
|
||||
type: 'post',
|
||||
data: $('#email-form').serialize(),
|
||||
success: function(data) {
|
||||
//whatever you wanna do after the form is successfully submitted
|
||||
$('#popup')
|
||||
.text('Added to list! Thank you for joining!')
|
||||
.slideDown()
|
||||
.delay(4000)
|
||||
.slideUp();
|
||||
// whatever you wanna do after the form is successfully submitted
|
||||
// $('#popup')
|
||||
// .text('Added to list! Thank you for joining!')
|
||||
// .slideDown()
|
||||
// .delay(4000)
|
||||
// .slideUp();
|
||||
console.log('successfully added email');
|
||||
},
|
||||
error: function(error) {
|
||||
$('#popup')
|
||||
.text('Email invalid or exists')
|
||||
.slideDown()
|
||||
.delay(4000)
|
||||
.slideUp();
|
||||
// $('#popup')
|
||||
// .text('Email invalid or exists')
|
||||
// .slideDown()
|
||||
// .delay(4000)
|
||||
// .slideUp();
|
||||
console.log('invalid or exists email');
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user