The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
![]()
Am currently working on a hack which would require the use of subcategories.
How can I go about with this ? As it is , the sql end has a table for the categories. Need I create another table for subcategories ? Am pretty lost as to where to begin. Any help would be most appreciated. |
#2
|
|||
|
|||
![]()
The best way to do this is to add a new colum to the categories table called 'parentid'. 'parentid' will contain the id of the of the categorie your sub-cat belongs to.
|
#3
|
||||
|
||||
![]()
You need to do some reading about recursive functions. I had to do this for my [top secret] project I'm working on but I did it but I have no idea how it works
![]() ![]() |
#4
|
||||
|
||||
![]() Quote:
![]() But even then I do not quite see how they can be used for sub cats ... could you elaborate further ? ![]() Quote:
What happens if a cat is not a subcat, ie a parent category ? Sorry but am pretty new to this ![]() |
#5
|
|||
|
|||
![]()
Set it to something like '0' by default when they are created if they are not a sub-cat.
|
#6
|
||||
|
||||
![]()
What brad said ^^ (I use -1 for some odd reason though)
![]() |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|