Hi, i'm trying to get a query string to work so that i can have text in the variable, like page.php?page=links instead of page.php?page=1 and i want the 'page' variable to select from another DB coloumn except the ID one. I think it is set up as it should be, but it's not working... if i put 'page=0' it displays the first DB entry, but if i put any other number it comes up blank, and if i put letters it comes up with a mysql error.
the code is:
$result = mysql_query("SELECT * FROM content WHERE title=$page",$db);
$myrow = mysql_fetch_array($result);
$text = $myrow["text"];
echo"$text";
title is the coloumn name i want to select, but when i put in the name of the 'title' for an entry, it comes up with an error.
http://excaliborg.co.uk/test/layoutqs.php?page=0
is the page. the two entrys under the 'title' coloumn are 'home' and 'test'
Hope you understand this, and can help!
cheers