views filters

Events happening in the community are now at Drupal community events on www.drupal.org.

Views Conditional Filter

Posted by mikeytown2 on January 26, 2011 at 2:17am

I'm well aware of Views Or; I'm looking for something that would do a Conditional Filter. Example:

I have a CCK field called showcase. If there is any node with the showcase field set to TRUE then I only want to display nodes of that type. But if none of my nodes have showcase selected then I would like to ignore this filter to still display nodes in this view. View has a random sort; also using sorting to do filtering doesn't seem like the correct way to do this.

Has anyone created a views plug-in like this?

Read more

Modifying Views Filters programmatically

Posted by timting on December 18, 2010 at 8:58pm

I've been trying to create a view for blog posts which given the url, say, "blog/after/2010/02/02", will take those arguments and give me the 10 entries in my blog after 2010年02月02日. I thought it would be relatively simple, but I haven't been able to find enough information on the web in order to do this. I'm not sure if I've taken the right approach. I've used http://groups.drupal.org/node/82219 as a template to use the hook_views_pre_view() function to access my view's filters (I've created a created filter on the blog entry post date) and modify it with the arguments on the URL.

Read more
9 comments Categories:
Subscribe with RSS Syndicate content

AltStyle によって変換されたページ (->オリジナル) /