tritus Posted September 13, 2007 Share Posted September 13, 2007 THIS IS THE ERROR I GET Parse error: syntax error, unexpected T_VARIABLE in /home/tritusco/public_html/booktrade/do_reg.php on line 28 someone please help? idk how to fix been trying for bit <?php $host = "localhost"; $dbuser = "tritusco_jeff"; $dbpass = "****"; $dbname = "users"; $dbconn = mysql_connect ($host, $dbuser, $dbpass); $db = mysql_select_db($dbname, $dbconn); //grab data from form $fname = $_POST[fname]; $lname = $_POST[lname]; $email = $_POST; $pass = $_POST[pass]; $passconf = $_POST[passconf]; //if else (else if) if($fname == false || $lname == fales || $email == false || $pass == false);{ echo "Please fill in all fields."; }; if($pass != $passconf){ echo "Passwords do not match."; }else { $db = mysql_select_db($dbname, $dbconn); $sql = 'INSERT INTO `tritusco_users`.`user` (`uid`, `date`, `time`, `fname`, `lname`, `email`, `pass`, `level`) VALUES (LAST_INSERT_ID(), CURDATE(), CURTIME(), '$fname', '$lname', '$email', ENCRYPT('$pass'), \'u\');';<br /> $result = mysql_query($sql); echo "Thank you for registering on SITENAME.com"; }; ?> Quote Link to comment https://forums.phpfreaks.com/topic/69231-solved-need-help-with-registration/ Share on other sites More sharing options...
janim Posted September 13, 2007 Share Posted September 13, 2007 try this $table="tritusco_users"; $insert=mysql_query("insert into $table values ('NULL','$fname','....................')") or die ("could not insert becouse ".mysql_error()); Quote Link to comment https://forums.phpfreaks.com/topic/69231-solved-need-help-with-registration/#findComment-347935 Share on other sites More sharing options...
tritus Posted September 13, 2007 Author Share Posted September 13, 2007 nope Quote Link to comment https://forums.phpfreaks.com/topic/69231-solved-need-help-with-registration/#findComment-347945 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.