We have a country based site that needs to have an unfiltered view of various content types and a filtered view per country. We have implemented the countries with Organic groups but can't seem to get the contextual filters to limit the view based on the OG name in the URL. Is there anyone that has done something like this with OG?


Under Relationships, I choose "OG membership: OG membership from Node".

Then under Contextual Filters, I choose "OG membership: Group ID".

The last step is to select the Provide default value and choose "Type: Current OG group from context" under the WHEN THE FILTER VALUE IS NOT IN THE URL heading. Attached is a picture of what I mean.

Contextual Filter setup


This link helped me: http://drupaleasy.com/blogs/ultimike/2013/05/sneaky-previously-undocumented-views-feature

It says it's for overriding the title, but should still work for your scenario.

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.