Closed (fixed)
Project:
OG User Roles
Version:
5.x-2.1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
12 Sep 2007 at 09:44 UTC
Updated:
17 Sep 2007 at 03:42 UTC
Hello,
OG User Roles is one of the very useful modules I use, and I thank you for having made it.
Nevertheless, I experienced what it seems to me to be a bug.
I have one role, Leader, which is assignated only to Group creators.
I have one block which I set a "Role specific visibility" on Leader role only.
When I create a group, I can't even display this block.
If I uncheck the "Role specific visibility", the block is displayed.
If I use some PHP code in "Page specific visibility settings", like
global $user;
if( function_exists( 'og_user_roles_all_roles' ) ) {
$all_roles = og_user_roles_all_roles($user);
}
// role id 6 is "Leader"
return ( isset($all_roles[6]) );
My block is displayed when I want.
Did I do something wrong?
Thank you for your help.
Comments
Comment #1
somebodysysop commentedFirst, install OG User Roles release 2.3 (or higher).
Second, apply the user.module patch discussed here: Buchan Milnes RPMs
Third, in OG User Roles settings, check on "Clear cache" option.
With these settings, I was able to create a role specific block that only appears to users in a specific role while in a group where the user has that role. In other words, I am able to do what you want to do.
Comment #2
somebodysysop commentedI'm sorry, I meant to write "the user.module patch discussed here: http://drupal.org/node/166566"
Comment #3
somebodysysop commentedModifications in version 5.x-2.4 which has just been released.