Page Manager user/%user/edit selection rule only called when user has 'administer users' permission I have a page manager page for user/%user/edit.

This page has a selection rule, for which I wrote a ctools access plugin.

(In my case the selection rule checks if the logged in user is the owner of an organic group, and the user being viewed is a member of that group).

The problem I have is that I get access denied.

In the debugger, the code does not even touch the ctools access plugin. It just checks if the user role has permission 'administer users'. The role doesn't have this permission, so I get access denied.

Interestingly, if I give the role the 'administer users' permission, then the code in my ctools access plugin runs!

In other words, page_manager_user_edit_page() is hit when the user has permission to get to the page anyway. What I need to happen is for page_manager_user_edit_page() to be hit always, because of course my og owners do not have global 'administer users' permission.

EDIT:

I ended up fixing the problem using hook_menu_alter() to call the function in the ctools access plugin.

In my case, it looks like this - I have a custom module (sites/all/modules/custom/og_user_admin/og_user_admin.module) where I call the access function.

 function og_user_admin_menu_alter(&amp;$items) {
   $items['user/%user/edit']['access callback'] = 'og_user_admin_access_edit_callback';
 }
use context rule in page manager page.

Home » Administration » Structure » Pages-> selection rule-> from drop down select role-> add-> assign role(selecting by check box).

done.