- 🇷🇴Romania claudiu.cristea Arad 🇷🇴
This version of Drupal is not supported anymore. If this is still an issue in the
8.x-1.x
branch, please open a new up-to-date ticket. Closing.
Hi, I'd like to add this to my own site and figured I'd check to see if anyone else was interested in this...
I have a site with fairly strict access controls - currently anonymous users are locked out completely. I'd like them to be able to view a small selection of content that's been specifically marked as "external." However, I'm also using OG to restrict visibility of some content even to logged-in viewers. In my context, I want "og_public" to mean "viewable by all logged-in viewers but not anonymous viewers." I'll then use my own custom module to grant some access to select content.
The fix is pretty simple. In og_access_node_grants, replace this:
if ($op == 'view') {
$grants['og_public'][] = 0; // everyone can see a public node
}
With this:
if ($op == 'view' && user_access('view public group content') ) {
$grants['og_public'][] = 0; // everyone can see a public node
}
plus the necessary boilerplate code to get the permissions right.
So - is this a feature that might make it into the build?
Closed: outdated
2.0
og_access.module
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
This version of Drupal is not supported anymore. If this is still an issue in the 8.x-1.x
branch, please open a new up-to-date ticket. Closing.