I created login form. When user clicks on login button this form shows up with some fade effect (jQuery). What I want to do is to display error message in this form when user inputs invalid data. Before showing any messages, PHP must read data from database, therefore page must be reloaded and when page is reloaded this form fade away. How can I display error message in this login form without reloading page?(I have lots of code so if you need any part of code I will provide)
Display error message with jQuery without reloading page
php;jquery;html5
What you are looking for is JQuery's ajax methods.They can get data from the server and update your dom on the fly without a page reload.This is pretty straightforward using Get or PostJQuery also has some other ajax methods which may be useful as well.