![]() |
| ||
| Php page containing html form to sql database Happy Holidays! I have a one field form. Upon submission with the submit button, I wish to drive this field value into my SQL database table called MEMBERS and field called NAMES, thus adding a new record. Can this be done with an OnSubmit() call to a function, in the HEAD of the HTML form page, which contains a series of statements opening the database, entering the data, and closing the database? <tr> |
| ||
| Re: Php page containing html form to sql database Create table in mysql-- create database in mysql with name db_name CREATE TABLE `table_user` ( in your php file you have to write like $con = mysql_connect("localhost","root","");your form structure like this <table> |
| ||
| Re: Php page containing html form to sql database Thank! Great response. How would you define the 'root' or do I leave the word 'root' as is. Where do I define the url to the server? |
| ||
| Re: Php page containing html form to sql database Oh, also...where is the connection script placed? Is that PHP or Javascript or HTML? Can I place it anywhere in the code? Thx |
| ||
| Re: Php page containing html form to sql database for localhost default user name and password user name--root password--"" (blank) if you want run on server create user name and password on server & use it |
| ||
| Re: Php page containing html form to sql database use at top..so make easy for you.. |
| All times are GMT -4. The time now is 6:51 pm. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC