Frank100 Posted June 22, 2007 Share Posted June 22, 2007 Hi, I’ve checked 2 books and 3 web tutorials on this, but the data still wouldn’t add to my customer table ... who can give me a hint what’s wrong. Here is the html form file <html> <body> Fill out to insert to table "customer"<p> <form name="form1" method="get" action="newcustomer.php"> Name: <input type="text" name="name"><p> Email address: <input type="text" name="email"><p> <input type="submit" name="Submit" value="Submit"> </form> </body> </html> Here is the process.php file <html><title>Simple Insert ...</title> <body> <?php $name = $_GET["name"]; $email = $_GET["email"]; $now = date("Y-m-d"); print "Name is $name<br>\n"; print "Email is $email<br>\n"; mysql_connect("localhost", "fhx", "dududu"); $result = mysql_query( "insert into phpbase.customer (name, email, signup, last_access) values ('$name', '$email', '$now', '$now')" ); if ($result) { print <<<EOT Inserting successfull ! EOT; } else { print "Inserting went wrong !"; } mysql_close(); ?> </body></html> This is my database www.hfpz.net/support/php/database_01.jpg Quote Link to comment https://forums.phpfreaks.com/topic/56730-database-insert-can%E2%80%99t-get-it-done/ Share on other sites More sharing options...
Frank100 Posted June 22, 2007 Author Share Posted June 22, 2007 got it ... the user didn't have the permission to write. Quote Link to comment https://forums.phpfreaks.com/topic/56730-database-insert-can%E2%80%99t-get-it-done/#findComment-280209 Share on other sites More sharing options...
ober Posted June 22, 2007 Share Posted June 22, 2007 Next time, please post in the right board. Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/56730-database-insert-can%E2%80%99t-get-it-done/#findComment-280278 Share on other sites More sharing options...
Frank100 Posted June 24, 2007 Author Share Posted June 24, 2007 ups ... which one would be the right board please ?? Also, why does my auto e-mail respond doesn't send e-mails when I get an answer ?? Regards, Frank Quote Link to comment https://forums.phpfreaks.com/topic/56730-database-insert-can%E2%80%99t-get-it-done/#findComment-281564 Share on other sites More sharing options...
ober Posted June 24, 2007 Share Posted June 24, 2007 http://www.phpfreaks.com/forums/index.php/board,1.0.html PHP Help or one of the DB boards. Quote Link to comment https://forums.phpfreaks.com/topic/56730-database-insert-can%E2%80%99t-get-it-done/#findComment-281602 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.