Hi i am newbie in coding.
Please help me.
I want to validate the HTML login page(email and password) with java script code .
And I want to connect that HTML login page to MySQL workbench server.
do i need to use php code for connectivity? please provide code.
when i enter wrong credentials it should redirect in same page and show error message beside email or password like invalid wrong email or password you typed.
What I have tried:
I have tried it but i am getting error message in pop up.I dont need pop up.
I have connected root localhost for MySQL workbech serverbut not fetching the credentials.
解决方案
You probably want to connect the MySQL database and not the Workbench (which is a software providing UI to your server)...
In nay case you can not connect your database from the client (where the HTML page is) using JavaScript... You need some server side code (PHP is good, but can be any other too), that JavaScript can talk to and will provide data services...
This may be a good starting point: PHP AJAX and MySQL[^]