faketales
10-29-2011, 06:08 PM
Hey i currently have an index page , within this index page i have a navigation bar.
What i would like to do is when a button is pressed , for example whe the button called "Fiction" is pressed i would like my page to redirect to my other page book_category_list.php.
On this page i would like all the books with the category list called "Fiction" to populate.
But if i pressed the button called "Horror" i would like the page book_category_list.php to populate the page with the categorys "Horror".
my current solution is to have a number of different pages and have this line of code on there.
this code is on the book_category_list.php page
$sql = mysql_query("SELECT * FROM books WHERE category='Fiction' ORDER BY date_added DESC");
so i would like where it says 'Fiction" to grab the value of the html link from the index.php page.
is this possible?
What i would like to do is when a button is pressed , for example whe the button called "Fiction" is pressed i would like my page to redirect to my other page book_category_list.php.
On this page i would like all the books with the category list called "Fiction" to populate.
But if i pressed the button called "Horror" i would like the page book_category_list.php to populate the page with the categorys "Horror".
my current solution is to have a number of different pages and have this line of code on there.
this code is on the book_category_list.php page
$sql = mysql_query("SELECT * FROM books WHERE category='Fiction' ORDER BY date_added DESC");
so i would like where it says 'Fiction" to grab the value of the html link from the index.php page.
is this possible?