I've probably missed something stupid, But can anyone see what is wrong with this?... $id = urldecode( $_GET['title'] ); $number = urldecode( $_GET['number'] ); echo $id; echo "<br>"; echo $number; (Works upto here) (Error...) $query = mysql_query('SELECT * FROM Gamepage WHERE number = $number'); $result = mysql_query($query); while($row = mysql_fetch_array($result)) { echo '<img src=/images/'. $row['Picture'] .' width="280" height="200" style="border-color: #000099" border="4"/>'; } Thanks alot,
replace: $query = mysql_query('SELECT * FROM Gamepage WHERE number = $number'); $result = mysql_query($query); PHP: with... $result = mysql_query("SELECT * FROM `Gamepage` WHERE `number` = '$number'"); PHP:
Skillman13, a small suggestion! Keep all your queries related to same module in single thread, that will be helpful to you when you have to look for solution of the same problem again
Skillman also please make sure to sanitize that input because as you have it right now it would VERY EASY for someone to inject sql