gammaman Posted April 21, 2008 Share Posted April 21, 2008 You guys were so helpful before I thought I would ask for help on this one. I do not get any errors but it does not preform the insert. mysql_query("Insert into Rcourse (CourseID,CourseName,StudentID,Password) Values ($CourseID,$CourseName,{$_SESSION['student']['user']},{$_SESSION['student']['pass']})"); Link to comment https://forums.phpfreaks.com/topic/102110-using-_session-vars-for-insert-query/ Share on other sites More sharing options...
zenag Posted April 21, 2008 Share Posted April 21, 2008 mysql_query("Insert into Rcourse CourseID,CourseName,StudentID,Password Values ($CourseID,$CourseName,'$_SESSION[student][user]','$_SESSION[student][pass]')"); Link to comment https://forums.phpfreaks.com/topic/102110-using-_session-vars-for-insert-query/#findComment-522699 Share on other sites More sharing options...
zenag Posted April 21, 2008 Share Posted April 21, 2008 mysql_query("Insert into Rcourse (CourseID,CourseName,StudentID,Password ) Values ($CourseID,$CourseName,'$_SESSION[student][user]','$_SESSION[student][pass]')"); Report to moderator 58.68.90.51 Link to comment https://forums.phpfreaks.com/topic/102110-using-_session-vars-for-insert-query/#findComment-522700 Share on other sites More sharing options...
DarkWater Posted April 21, 2008 Share Posted April 21, 2008 You guys were so helpful before I thought I would ask for help on this one. I do not get any errors but it does not preform the insert. mysql_query("Insert into Rcourse (CourseID,CourseName,StudentID,Password) Values ($CourseID,$CourseName,{$_SESSION['student']['user']},{$_SESSION['student']['pass']})"); Trying running the query in the MySQL console window. @Guy who posted above me: No. He needs the { }. Link to comment https://forums.phpfreaks.com/topic/102110-using-_session-vars-for-insert-query/#findComment-522704 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.