How to restrict views page and contents by taxonomy term role, but provide a global text message publicly

In some instances, you may want to restrict your views page (in this case to permit only selected roles to view contents categorized in certain taxonomy terms). You also, however, will want some text available and viewable publicly on the same Views URL or page. To do this, you may follow these simple steps.

Taxonomy Access Control Lite (TAC) Module

  1. Install the TAC module
    https://www.drupal.org/project/tac_lite
     
  2. Configure a scheme, e.g. View content, then limit or allow permissions by role. This completely hides the Views page and content. However, this will completely render the view as Access denied, with all the global header/text messages blocked as well.

Views Role Based Global Text Module

  1. Comes in Views Role Based Global Text module
    https://www.drupal.org/project/views_role_based_global_text
     
  2. Install and configure to allow display for anonymous (public) role. There is a "Role" setting while entering text either on header or footer. 

See also related article Drupal 7 Views - How to show a global text message publicly but hidden for logged in users

Other similar modules:

Leave a Comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
To prevent automated spam submissions leave this field empty.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.
10 + 2 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.
Get reliable web hosting services

Recurring donation

Make Donation

  • Other: $

Donate now

Single donation

Make Donation

  • Other: $

Donate now