whare Posted August 15, 2006 Share Posted August 15, 2006 Hi AllI keep getting this error and i have tried other wass of sorting the problem but carnt seem to work it outAny Ideas??Parse error: parse error, unexpected T_STRING in /home/www/evtecsolutions.com/dashairways/pirep2/includes/pirep.php on line 23Here is my code[code]<?// Session and include infosession_start();include 'config.php';// Form Field info$fltnum = $_POST['fltnum'];$actype = $_POST['actype'];$depair = $_POST['depair'];$deptime = $_POST['deptime'];$arair = $_POST['arair'];$artime = $_POST['artime'];$flttime = $_POST['flttime'];$fltinfo = $_POST['fltinfo'];$userid = $_SESSION['userid'];// SQL to update the table "pirep"$sql = mysql_query("INSERT INTO pirep (userid, fltnum, actype, depair, deptime, arair, artime, flttime, fltinfo, pirep_date) VALUES('$userid','$fltnum','$actype','$depair','$deptime','$arair','$artime','$flttime','$fltinfo', now())") or die (mysql_error())// SQL table to update "pilot" [this is the bit with the error mysql_query("UPDATE pilot SET lastpirep=now() WHERE userid='$userid'"); echo "Thankyou for your Pirep.";?>[/code]Thanx AllWhare Link to comment https://forums.phpfreaks.com/topic/17644-db-submit-error-i-think-lol/ Share on other sites More sharing options...
hitman6003 Posted August 15, 2006 Share Posted August 15, 2006 For one, your missing the semicolon at the end of this line:[code]$sql = mysql_query("INSERT INTO pirep (userid, fltnum, actype, depair, deptime, arair, artime, flttime, fltinfo, pirep_date) VALUES('$userid','$fltnum','$actype','$depair','$deptime','$arair','$artime','$flttime','$fltinfo', now())") or die (mysql_error())[/code] Link to comment https://forums.phpfreaks.com/topic/17644-db-submit-error-i-think-lol/#findComment-75226 Share on other sites More sharing options...
whare Posted August 15, 2006 Author Share Posted August 15, 2006 It is amasing how easy it is to forget that lolI will check it and see if it works lol Link to comment https://forums.phpfreaks.com/topic/17644-db-submit-error-i-think-lol/#findComment-75229 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.