1

I have a content type called article where i have 6 fields.

But i need to display and hide this fields based on user group while add and edit node.

I am confused about which hook should i use.I am planning to use hook_page_alter().Please let me know wheather it is the correct hook i am using.Thanks a lot.

1 Answer 1

0

If I understand you right you'd be better off using the Field Permissions module:

The Field Permissions module allows site administrators to set field-level permissions to edit, view and create fields on any entity.

If you do code it yourself you're going to end up implementing most of that modules functionality, so even if you don't use it it's a great place to look for the right hooks to call etc.

1
  • Thanks for the suggestion.I need to filter fields based on organic group.does the Field Permissions module support organic groups.
    – nagakumar
    Sep 12, 2012 at 1:01

Your Answer

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

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