GRooVeZ Posted May 6, 2012 Share Posted May 6, 2012 hi i insert some values in a table, that goes well but right after the insert, i call the value of $matchidcheck, wich has just been inserted to the db correctly and it gives me the value of 0 ... in the $mes so it isnt forwarding correctly either how is this possible? $insertSite_sql3 = "INSERT INTO ffa_mapvotes (matchid,playerid,mapid,mapname) VALUES ($matchidcheck,$playerid,$vote3,'$vote3checker')"; $insertSite3= mysql_query($insertSite_sql3); $mes="$matchidcheck Vote Succesfull ... Please Wait ..."; return success($mes,'./ffacheckin.php?match=$matchidcheck'); if i replace the last line with return success($mes,'./ffacheckin.php?match=112'); it works ... Link to comment https://forums.phpfreaks.com/topic/262156-value-lost-after-insert/ Share on other sites More sharing options...
smerny Posted May 6, 2012 Share Posted May 6, 2012 try return success($mes,"./ffacheckin.php?match=$matchidcheck"); php doesnt parse variables in single quotes Link to comment https://forums.phpfreaks.com/topic/262156-value-lost-after-insert/#findComment-1343486 Share on other sites More sharing options...
GRooVeZ Posted May 6, 2012 Author Share Posted May 6, 2012 the problem is it giving me a 0 as value instead of the id wich has been inserted ... but thx for that Link to comment https://forums.phpfreaks.com/topic/262156-value-lost-after-insert/#findComment-1343491 Share on other sites More sharing options...
GRooVeZ Posted May 6, 2012 Author Share Posted May 6, 2012 i replaced the line, and it worked ! thx man ! Link to comment https://forums.phpfreaks.com/topic/262156-value-lost-after-insert/#findComment-1343492 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.