Any ideas on how to archieve that?
Jul 17, 2002, 2:35 PM
Veteran / Moderator (18441 posts)
Jul 17, 2002, 2:35 PM
Post #2 of 4
Views: 2627
How about adding a plugin, that checks if the category has a father ID? If it doesn't, then its a root catgory (guessing here..as I've never done this before).
Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Jul 17, 2002, 9:08 PM
User (64 posts)
Jul 17, 2002, 9:08 PM
Post #3 of 4
Views: 2597
I managed to achieve this (with the PHP front-end) by adding an ENUM column to the category table called "CanAdd" and editing the query (Utils.inc.php in the PHP version) where the category list is generated to include:
SELECT ID, Full_Name FROM ${PREFIX}Category WHERE CanAdd ='Yes' ORDER BY Full_Name
If you set the default value of CanAdd to "Yes", then all you need to do is update the categories you don't want people adding links to by changing the value to "No".
I don't know Perl, so I'm not sure exactly which bits you'd need to edit to make the changes successfully, however someone with Perl knowledge might be able to re-interperet this into something useful for you.
Regards,
Amanda
SELECT ID, Full_Name FROM ${PREFIX}Category WHERE CanAdd ='Yes' ORDER BY Full_Name
If you set the default value of CanAdd to "Yes", then all you need to do is update the categories you don't want people adding links to by changing the value to "No".
I don't know Perl, so I'm not sure exactly which bits you'd need to edit to make the changes successfully, however someone with Perl knowledge might be able to re-interperet this into something useful for you.
Regards,
Amanda