posted 5 years ago
I am writing a simple signup form where I am using Ajax call to implement this functionality.
I am using jquery for the ajax call.
I am trying to fetch the data from form using ajax and insert that form data in database and if the email entered by the user is distinct or unique then the data is inserted otherwise result failed is shown.
This code here doesn't seem to work. The ajax call is completing successfully, but I am getting error saying all the fields that I have in the model User are empty which is also the reason why this data is not being inserted in the database.
Here is the model class :-
I have removed the validation annotations from it thinking that those constraints were somehow responsible for this behaviour
Here is my controller class :-
This is my html form that I am working with :-
Please don't mind the alignments. Here is the js file which is executing the ajax call
If you can please help me with this.
Thanks in advance
DRAGON SWALLOWED HIM... END OF STORY