Page is a not externally linkable
lostdreamer - 10:24 am on Sep 13, 2012 (gmt 0)
if you want to view all the pages for all the categories, you should not have a WHERE clause there ;)
if(isSet($category) && $category != "")
$query = "SELECT * FROM pages WHERE category='". $category ."' ORDER BY name";
else
$query = "SELECT * FROM pages ORDER BY name";
Something like that.
What you **could** do, but note this is NOT best practise:
$query = "SELECT * FROM pages WHERE category LIKE '". $category ."' ORDER BY name";
With LIKE instead of WHERE you can do wildcard searches by using "%" so " category LIKE '%' " gives you all results