Site structure
Version 5.x > Site structure > Hierarchical Categories Prior to V6 View modes: 
User avatar
Certified Developer 11
Certified Developer 11
lee-craftedmedia - 12/6/2010 4:42:38 AM
   
Hierarchical Categories Prior to V6
What is the best way to implement hierachical categories in the current version?

I know it will not be available until the next release (v6 - Q2/3 2011) but we cannot wait for that version and need to be able to associate a page to multiple hierarchical categories for programmatic use.

I have ruled out tags/current single categories, related documents etc because the way we would like it to work is:

- Create a new page anywhere on the site
- From the forms tab have a checkbox tree view of the hierachical categories
- Tick all categories that apply and save page
- From a custom user control for example be able to search for all pages that have a specific category association (no matter what the parent node is)


The current Related documents functionality is the closest functionality to what we want but is too slow - added one at a time - not a multi-select treeview.

The way I am looking at doing this currently is to use a custom form field in a similar way to this: http://devnet.kentico.com/docs/devguide/index.html?developing_form_controls.htm


But the control will be a TreeView and will fetch data from a config file or custom database table and I will store the selected values as a comma delimited list (as form controls store single values not mulitple values).

Does this sound a feasible approach - any alternative ideas appreciated?

Thanks,
Lee.




User avatar
Kentico Support
Kentico Support
kentico_zdenekc - 12/13/2010 6:27:16 PM
   
RE:Hierarchical Categories Prior to V6
Lee,

As I wrote also in the email (I just want to reply here for others too),
to build hierarchical categories in general scale is not an easy task.
Your discussed solution would be possible using custom Form control,
the storage of the information and structure is however up to you... comma separated values may be fine, however more difficult to reflect changes made to the category structure. Ideally, couple of connected custom tables would allow more robust approach.

Maybe if you could send us any ideas/thoughts how would you try to define the storage structure, we could give more suggestions...

Thanks and regards,
Zdenek