Reply To: contact form will not work

Support Forums Gris – HTML Template contact form will not work Reply To: contact form will not work

#5534
CreaboxThemes
Keymaster

Hi Steve,

I don’t know the problem exactly when it happens a 500 server error.

We can try the next solution. In you file scripts.js, look for the next code:

$contactform.submit(function(){
     $.ajax({
          type: "POST",
	  url: "php/contact.php",
	  data: $(this).serialize(),
	  success: function(msg)
	  {
	       if(msg == 'SEND'){
	            $('.error-message-2').hide();
                    $('.success-message-2').hide();
                    $contactform.hide().delay(3000).fadeIn();
                    $('#contactform input').val('');
                    $('#contactform textarea').val('');
                    $('.success-message-2').html('<div class="success-message-2">'+ $success +'</div>');
                    $('.success-message-2').fadeIn().delay(2000).fadeOut();
	       }
	       else{
		    $('.success-message-2').hide();
                    $('.error-message-2').hide();
                    $('.error-message-2').html('<div class="error-message-2">'+ msg +'</div>');
                    $('.error-message-2').fadeIn().delay(3000).fadeOut();
	       }
	  }
     });
     return false;
});

Change the option type: “POST” to type: “GET” and tell me if it works.

Regards