0

My Drupal version is 7.50.

I want to show to anonymous user a list with a specific fields (title, image, body abstract), but when you click in title, the content of that node would only be available to registred users.

I tried combining Views to make that list with "Node Access" to limit access to node... but I'm lost. Surely, I'm doing something wrong.

Any suggestion about it? Thanx!

  • 1
    In other words, show a teaser to anonymous, but when they try to view the actual node, they cannot? – No Sssweat Jul 31 '16 at 0:28
  • Yes! Excellent summary :-) That's exactly what we want to do . – Jordi Molas Aug 1 '16 at 13:11
0

I think Field Permissions is right module for you.

Features

  • Enable field permissions on any entity, not just nodes.
  • Role-based field permissions allowing different viewing patterned based on what access the user has.
  • Author-level permissions allow viewing and editing of fields based on who the entity owner is.
  • Permissions for each field are not enabled by default. Instead, administrators can enable these permissions explicitly for the fields where this feature is needed.
  • Field permissions overview
  • Great @codenext! Let me ask you one more question. When one user try to read that node, is it possible to display a special message inviting him to register instead an empty page? Something like: "To read this content is required to be registered. Click here to sign up now". – Jordi Molas Aug 2 '16 at 17:29
  • I think, that would be easy. Above the main content you can add one new field i.e. AccessMessageDisplay and you can add message what you want. AND for this field you have to set the permission accordingly, So on that page, other content will not display for That User role, but this Field of message will display for that User role and you can add Link to Login-page, so use can redirect from that page. – CodeNext Aug 2 '16 at 18:09
  • Totally agree. Tested and working. Thnx again! – Jordi Molas Aug 3 '16 at 14:24
0

If I understood properly.

Create a page view with your fields(which you want to show to all users) title, image, body abstract and set the access to all.

And give the node view access only to authenticated user.

Hope that will help.

  • @Jordi Molas did it help? – Nabajit Roy Aug 1 '16 at 14:01
  • Hi Nabajit! Finally we have implemented the suggestion of @codenext and has been totally satisfactory. Thanks for your interest! – Jordi Molas Aug 3 '16 at 14:24
  • If that helped please vote my answer. – Nabajit Roy Aug 5 '16 at 8:05
0

The Field Permissions module CodeNext propose is nice because it will allow you to define witch fields are available for witch role.

However, it can be also really interesting for you to look at the Node Option Premium module, witch allow you to define roles with proper privileges to view the full content of the node. User without the proper permission will only see the teaser of your content and a message saying this content is reserved for members.

When a node is published as premium content, only users with proper privileges may view the full content of the node.

Non-premium users can still access premium nodes but only get the content rendered in teaser context, even when trying to view the full content. An additional message informs them that the content is available to premium users only.

You can also use both module together (Field Persmissions and NOPremium), and also have some fields shown to specific roles.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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