0

I have a menu tab on nodes which is visible to everyone on the site. But I want it to be user specific. If the logged in user is the one who created that node, only he should be able to see the menu tab. Is it possible to do this using views ?

1

2 Answers 2

0

Using Views, you can add tabs and set argument (aka contextual filter) validators.

user will not see the tab if the argument is invalid.

See this post. You will need to set arguments as described in this post.

0

You can always add access argument "edit own page content" replace page with you content-type name. If you want more complex permissions you can add your own access callback to a menu item which will return true or false. For further information check http://api.drupal.org/api/drupal/modules%21system%21system.api.php/function/hook_menu/7

6
  • I created the menu tab using views not programmatically. So can i do this using views ?
    – Jayaram
    Jun 7, 2012 at 14:04
  • You can also this in views under page settings->menu->select menu tab->fill out the details and choose Navigation menu. After saving view clear cache.
    – jibran
    Jun 7, 2012 at 14:18
  • I created the menu tab, the issue it setting the access permissions! under the permissions i don't see 'edit own page content'
    – Jayaram
    Jun 7, 2012 at 16:41
  • In access permission settings under node option group Basic Page: Edit own content.
    – jibran
    Jun 7, 2012 at 17:47
  • Can i do something where I can set it for all the content types and not just basic page ?
    – Jayaram
    Jun 7, 2012 at 18:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.