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

somebodysysop’s picture

Assigned: Unassigned » somebodysysop
Status: Active » Fixed

First, 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.

somebodysysop’s picture

Second, apply the user.module patch discussed here: Buchan Milnes RPMs

I'm sorry, I meant to write "the user.module patch discussed here: http://drupal.org/node/166566"

somebodysysop’s picture

Status: Fixed » Closed (fixed)

Modifications in version 5.x-2.4 which has just been released.