greenbman Posted December 15, 2012 Share Posted December 15, 2012 Ok here is the Error: [color=#000000][font='Times New Roman'][size=1]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'The Reply system works... So that means the entire Communications Array is up an' at line 1[/size][/font][/color] This is the code now the message field is set to text in SQL FUNCTION sendSloppyCheeseTransmission($to,$from,$subject,$message){ $date = date("Y-m-d H:i:s"); $time = time(); $q = "INSERT INTO `messages` SET `to` = '{$to}', `from` = '{$from}', `subject` = '{$subject}, `message` = '{$message}', `date` = '{$date}', `time` = '{$time}'"; $res = mysql_query($q) or die(mysql_error()); if(isset($res)){ return 1; } } Any Help Would be Awesome, greenbman Quote Link to comment https://forums.phpfreaks.com/topic/272035-error-in-syntax/ Share on other sites More sharing options...
MDCode Posted December 15, 2012 Share Posted December 15, 2012 `subject` = '{$subject} Missing an apostrophe Quote Link to comment https://forums.phpfreaks.com/topic/272035-error-in-syntax/#findComment-1399574 Share on other sites More sharing options...
greenbman Posted December 15, 2012 Author Share Posted December 15, 2012 Ha ha... It's the Small things in PHP that Throws you off in Programming. Thanks for the keen eye. Quote Link to comment https://forums.phpfreaks.com/topic/272035-error-in-syntax/#findComment-1399575 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.