| | |
creating a multi-level category search/navigation system
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Apr 2008
Posts: 35
Reputation:
Solved Threads: 0
hi, i'm creating the admin section for a multi-level category search/navigation system. i mean like, when a visitor comes to the site and they are looking for data, first a list of categories appears. for example ..... states....departments......etc. so when a user clicks on states, he gets another list of subcategories, and it can go on till he reaches the file/info he's looking for. i also wanted to make it multi dimensional so that a particular piece of information could be reached by different paths.
on the admin side, i dont want to put a limit on the number of categories/levels an administrator can put in.
Now my problem is figuring out the logic necessary to sort and store the data when the administrator uploads them so that in the front end, it would be easy for visitors to find them.
does anyone have any ideas how i can go about this?
on the admin side, i dont want to put a limit on the number of categories/levels an administrator can put in.
Now my problem is figuring out the logic necessary to sort and store the data when the administrator uploads them so that in the front end, it would be easy for visitors to find them.
does anyone have any ideas how i can go about this?
Sounds like you should be able to add several categories to a piece of data (say a record), allowing it to be reached by different paths. Next to that you would need to have your categories setup in a table (or multiple), ordering them the way you need them (parent, child) in your search system. Much like a menu system. You define a category, and what other category is it's parent. Can you give an example of how one piece of data would be reached by different paths ?
"If it is NOT source, it is NOT software."
-- NASA
-- NASA
i suggest: setting up a table that has fields determine what the sub catagories parent is. That is is the easiest way. When displaying the links, you will need to select all from the database were the parent category is equal to the previous link clicked. I suggest you do this with ajax and use php and a mysql database with the fields like so:
Parent | Link
Parent | Link
![]() |
Other Threads in the PHP Forum
- Previous Thread: Please help to find the whois of .in, .co.in etc.
- Next Thread: basic > php mail() - configuration
| Thread Tools | Search this Thread |
Tag cloud for PHP
.htaccess access ajax apache api array beginner binary body broken cakephp checkbox class cms code cron curl database date date/time directory display download dynamic echo email error file files folder form forms function functions google href htaccess html image include insert integration ip java javascript joomla limit link list login loop mail menu mlm mod_rewrite msqli_multi_query multiple mycodeisbad mysql oop parse paypal pdf php problem query radio random recursion regex remote script search send seo server sessions sms soap source space sql static structure syntax system table tutorial update upload url validation validator variable video web webdesign wordpress xml youtube





