2

I have a view that I need to filter using the logic Field_a Contains url_argument_1. Or in SQL Field_a LIKE '%url_argument_1%'. The problem I am having is only filters let me use the "Contains" operator and only Arguments let me access url_argument_1. How can I combine them?

Just for clarity url_argument_1 is Argument #1 that is passed into the view from the URL. Also, if at all possible I want to avoid writing a custom module. I prefer to do this via the views interface.

1

Solution would be to filter results by argument value. Unfortunately, this doesn't seem to be doable in Views at the moment. Not via the Views interface, anyway.

However, by altering exposed filter form to set current argument value as filter default value, users have managed to get such functionality to work: http://drupal.org/node/360780

I don't know what state it is in, but you may want to have a look at this module, which is supposed to do just that -- enable using argument placeholders (%1, %2) as filter values: http://drupal.org/sandbox/itangalo/1086472 (git only)

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.