noisyscanner Posted April 25, 2009 Share Posted April 25, 2009 My form handler: <?php mysql_connect("localhost","user","pass"); mysql_select_db("db"); mysql_query("INSERT INTO userpage (`wmsg`) VALUES ('$_POST[msg]')") or die(mysql_error()); ?> I submit the form but when I check phpmyadmin it has inserted blank info. There has got to be something wrong here. Please help. Link to comment https://forums.phpfreaks.com/topic/155606-why-is-my-text-box-not-inserting-data-into-the-mysql-database/ Share on other sites More sharing options...
Mchl Posted April 25, 2009 Share Posted April 25, 2009 echo $_POST['msg'] to see if there's anything in it actually Link to comment https://forums.phpfreaks.com/topic/155606-why-is-my-text-box-not-inserting-data-into-the-mysql-database/#findComment-818944 Share on other sites More sharing options...
noisyscanner Posted April 25, 2009 Author Share Posted April 25, 2009 It echo's nothing Link to comment https://forums.phpfreaks.com/topic/155606-why-is-my-text-box-not-inserting-data-into-the-mysql-database/#findComment-818952 Share on other sites More sharing options...
Mchl Posted April 25, 2009 Share Posted April 25, 2009 Probably something wrong with your form. Link to comment https://forums.phpfreaks.com/topic/155606-why-is-my-text-box-not-inserting-data-into-the-mysql-database/#findComment-818954 Share on other sites More sharing options...
fenway Posted April 27, 2009 Share Posted April 27, 2009 How about echo-ing the sql statment? Link to comment https://forums.phpfreaks.com/topic/155606-why-is-my-text-box-not-inserting-data-into-the-mysql-database/#findComment-819973 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.