The question is a pretty simple one, I've created a page-view with an exposed filter. The page-view itself contains a block-view. I was wondering if the value of the exposed filter (which is in the url) could be used as a contextual filter in the block-view.

So far I've tried 'get content ID from url' and 'get raw value' but neither seem to work as the block-view returns no results.

1 Answer 1


Please follow below steps to achieve functionality that you are looking for.

  1. Disable AJAX feature for view.
  2. In the block view add a contextual filter and select type as Provide default value >> Type as php code.
  3. In the php code read the exposed filter value using $_GET[]
  4. Return the value you got from $_GET to contextual filter.

In that way you can able to pass exposed filter value to the contextual filter.

  • Works, cheers mate.
    – Zedicius
    Sep 12, 2012 at 9:26

Your Answer

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

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