Features / Usability

Features / Usability

Categories and Permissions

posts: 21

I'm trying to create a website in which the anonymous user should have no access (no global groups permissions) except for the pages that I've categorized permissions for them. However, when I go to test the page as anonymous, I keep getting the permission denied error.

I've tried to solve this problem for days. Frustrated, I finally look into the source code and track down exactly why. The result is that I've found that in my fresh installation of tikiwiki 2.0, only two category permissions are allowed (this seems a bit odd considering the info in "category details" page): tiki_p_view_categories and tiki_p_admin_categories. There is a check a long ways down the code that gives tiki_p_view access if:

$categPerms'tiki_p_view_categorized' 'y' or $categPerms'tiki_p_edit_categorized' 'y' or $categPerms'tiki_p_admin_categories' == 'y'

It seems that having tiki_p_view_categories permissions on the object does absolutely nothing for $tiki_p_view. In other words, the check doesn't care what the value in tiki_p_view_categories is and by default, it prevents viewing of wiki pages.

Looking at the category details, if I'm interpreting the permissions correctly, tiki_p_view_categories should give me what I want anyways - view access to the objects (wiki pages) in categories. So by logic, the if statement should look at tiki_p_view_categories and not tiki_p_view_categorized.

I also find it odd that there would be only two permissions assignable in the drop down menu of the categories admin. Did I do something wrong?

posts: 289 United States
Go to tiki-admin_system.php and clear the /temp/cache. You should now see 4 category permissions instead of 2.

posts: 21

I just upgraded to 2.1...and its fixed!