Hello guys. I’ve been looking for a Pagination script that would search for results based on game categories. I have been given links to people who already made Pagination scripts but they don’t do what I am looking for. It’s frustrating. Just to let everybody know, I am a noob. I am still learning PHP. It’s been 2 weeks since I’ve been looking for pagination and I can’t seem to have one that fits my page. I’d really like it if somebody written it for me if they have the time and maybe others can benefit from the script as well.
Here is a table that I have in my database:
fldID | fldTitle | fldCategory | fldIconMedium | | fldLink |
2415 Krusty Fun House Skills krusty.jpg games.php?id=2415
2415 Krusty Fun House Skills krusty.jpg games.php?id=2415
2415 Krusty Fun House Skills krusty.jpg games.php?id=2415
2415 Krusty Fun House Adventure krusty.jpg games.php?id=4536
2415 Krusty Fun House Skills krusty.jpg games.php?id=2415
2415 Krusty Fun House Action krusty.jpg games.php?id=1511
2415 Krusty Fun House Skills krusty.jpg games.php?id=2415
2415 Krusty Fun House Shooter krusty.jpg games.php?id=6631
2415 Krusty Fun House Action Krusty.jpg games.php?id=6631
2415 Krusty Fun House Shooter krusty.jpg games.php?id=6631
2415 Krusty Fun House Mind krusty.jpg games.php?id=6631
Heres what Id like to see the user do when they want to search for a particular game category from my mysql database:
-
For example, user types in ‘http://www.blabla.com/gameslist.php?cat=action’. Notice ‘gameslist.php?cat=action’ where it searches for the word ‘Action’ in the ‘fldCategory’ column in the database you see above. Once it finds the rows containing the word ‘Action’ from ‘fldCategory’, it displays each games containing the word ‘Action’ from ‘fldCategory’ column. This could also apply for skill games ‘gameslist.php?cat=skills’, or adventure games ‘gameslist.php?cat=adventure’ etc… etc…), and it would search those names from the ‘fldCategory’ column to identify the category name, then fetch the all game information from the database containing that category name.
-
The Search results are viewed in the gameslist.php.
-
The results are displayed like this:
Page 1 of 7
Action games found: 131
========== ========== ========== ========== ==========
fldIconMedium fldIconMedium fldIconMedium fldIconMedium fldIconMedium
Image Image Image Image Image
========== ========== ========== ========== ==========
Title (fldTitle) Title (fldTitle) Title (fldTitle) Title (fldTitle) Title (fldTitle)
========== ========== ========== ========== ==========
fldIconMedium fldIconMedium fldIconMedium fldIconMedium fldIconMedium
Image Image Image Image Image
========== ========== ========== ========== ==========
Title (fldTitle) Title (fldTitle) Title (fldTitle) Title (fldTitle) Title (fldTitle)
First < Previous 1 2 3 4 5 6 7 Next > Last
Hence knowing that ‘fldIconMedium’ is the column in the database containing the image links, and ‘fldTitle’ is the column in the database containing the Title of each game.
The entire pagination shows Images of the games with their Titles underneath them in a table horizontally, and they are hyperlinked to their links from the ‘fldLinks’ column in the database which has the links to the games. Overall, the number bar bellow increases or decreases depending on how many games of the same category have been found. Including its next and previous buttons.
Would anybody help?
Thanks. :injured: