By feloescoto on
Hello, I am trying add a category in the user edit page and to restrict access to it:
if($op == 'categories'){
$data[] = array(
'name' => 'name',
'title' => 'The Title',
'access arguments' => array('perms required')
);
return $data;
}
It is supposed to appear only for the roles with 'perms required', but it does not appear to anyone.
If I remove the access arguments it works perfect.
I'm I on the right track?
Regards.
(edit the title said hook menu, I changed it)
Comments
You don't have a page
You don't have a page callback.
Contact me to contract me for D7 -> D10/11 migrations.
sorry, what do you mean by
sorry, what do you mean by that?
the list has access callback and access arguments, should I include a page callback?
If you don't have a page
If you don't have a page callback, there is nothing for the path to show. The page callback generates the the page that the user will see.
Contact me to contract me for D7 -> D10/11 migrations.
thanks, but the hook_user
thanks, but the hook_user does not give me a page callback option?
How would I include that?
You realize the thread title
You realize the thread title is asking about hook_menu right?
Contact me to contract me for D7 -> D10/11 migrations.
my bad
I changed that already, thanks for pointing it out :)