• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 2.0 About Node permissions

Nirjonadda

Well-known member
#1
I have set Node permissions Inherit for Administrative usergroup but still are marked in red color. Please let me know that why still are marked from red color?


 

Chris D

XenForo developer
Staff member
#3
It likely means there are orphaned permission values in the database which are no longer displayed because the permission definition no longer exists. This can happen, mostly in XF1, when an add-on is uninstalled which doesn't remove any of the permissions that were set.

Under Tools > Rebuild caches, run the "Clean up permissions" tool which should remove any orphaned permission values.
 

Nirjonadda

Well-known member
#4
It likely means there are orphaned permission values in the database which are no longer displayed because the permission definition no longer exists.
This issue happening only for one Node permissions.

Under Tools > Rebuild caches, run the "Clean up permissions" tool which should remove any orphaned permission values.
Done lot of time but still are marked from red color.
 

Nirjonadda

Well-known member
#5
@Chris D Please note this issue happened only for one Node permissions with Administrative User groups. All other User groups Node permissions does not have this issue. So please let me know that what the wrong with this Node permissions for Administrative User groups?
 

Chris D

XenForo developer
Staff member
#6
The clean up permissions tool should work, only thing I can suggest is perhaps trying to go back into Administrative and setting a permission and saving, then going back in and setting all back to inherit and saving again. Just in case there's some sort of cache at play here (though I think the clean up permissions tool sorts that).

Only other thing I can suggest is finding out what the node_id of the node is and running this query:
SQL:
SELECT *
FROM xf_permission_entry_content
WHERE content_type = 'node'
AND content_id = 12345
AND user_group_id = 3
(Replace 12345 with your actual node_id for the affected forum).

That should tell us if there are any orphaned permission values left over.
 

Nirjonadda

Well-known member
#7
The clean up permissions tool should work, only thing I can suggest is perhaps trying to go back into Administrative and setting a permission and saving, then going back in and setting all back to inherit and saving again. Just in case there's some sort of cache at play here (though I think the clean up permissions tool sorts that).
I set one time to Inherit, Yes, No and Never but still are not get the red color change.

 

Chris D

XenForo developer
Staff member
#9
Is exclude_force_threads from an add-on? Is the add-on currently disabled? If so, that permission is still set but it won't be shown in the UI because it's disabled. You could re-enable the add-on and set the permission to inherit to sort the problem.
 

Nirjonadda

Well-known member
#12
Probably best to just ignore it then for now. It’s hardly problematic.
I have not plan using this add-on. So how can remove this add-on data?

This add-on Installer.php table code.

Code:
        $tables["xf_force_editor_button_remove"] = "
            CREATE TABLE IF NOT EXISTS `xf_thread_view_force_guests` (
              `session_id` char(32) NOT NULL DEFAULT '0',
              `thread_id` int(10) unsigned NOT NULL DEFAULT '0',
              PRIMARY KEY (`session_id`)
            ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
            ";
        
        $tables["xf_thread_view_force_users"] = "
            CREATE TABLE IF NOT EXISTS `xf_thread_view_force_users` (
              `user_id` int(10) unsigned NOT NULL DEFAULT '0',
              `thread_id` int(10) unsigned NOT NULL DEFAULT '0',
              PRIMARY KEY (`user_id`)
            ) ENGINE=InnoDB DEFAULT CHARSET=utf8;