i am trying to insert data in a ‘songs’ column of a table with name same as the current session variable username. but it is giving following error
Parse error: syntax error, unexpected ‘”‘, expecting T_STRING or T_VARIABLE or T_NUM_STRING
mysql_query("INSERT INTO ".$_SESSION['username']."('songs') VALUES(\"$_FILES["file"]["name"]\")");
Try this instead:
The quotes in the variable were causing the problem.