0

I've scoured the site for solutions, and I have no idea what's going on. I have drupal 7 running off a local installation (mamp), and my site is structured with Panels and Panels Everywhere. I have a view that is in the sidebar, and I want it to pull up anything tagged with the name of the page. (for example walldamp/drupal/architecture would pull up architecture, or walldamp/drupal/acoustics would pull up all nodes tagged with acoustics).

The preview works just fine when I type in a tag, but it just won't work with the sites. If anyone could help, I'd really appreciate it.

I'll post a picture as soon as I get more reputation, but currently my settings are as follows for the contextual filter.

  • Configure contextual filter: Content: Has taxonomy term ID
  • Provide Default Value
  • Raw Value form URL
  • Path Component: 3
  • Exception Value: All
  • Specify Validation Criteria
  • Validator: Taxonomy Term
  • Filter Value Type: Term Name converted to Term ID
  • Transform dashes in url to spaces in term name filter values
  • Action to take if filter value does not validate: Display a summary.

It's just displaying the summary in my sidebar, no actual blog posts or images like in the preview. Any help would be appreciated.

2 Answers 2

1

Try using argument 2 (URL arguments start at 0 not 1) as opposed to argument 3. A Failing that, disable the validation, oftentimes the validation is screwy and excludes valid content. Start with as little filtering, validation, exclusion, etc. to make sure you're getting data and tighten the parameters from there.

11
  • I tried both of those to no avail. When I take away the contextual filter, and just use a regular taxonomy filter, it works fine, but when i use the contextual filter, nothing. Commented Sep 19, 2012 at 18:05
  • Maybe there's a better way to be doing this? Would it be easier to just put a taxonomy field on each node, and have it call from that? (For example, any nodes having to with acoustics would call all other nodes having to with acoustics into that sidebar.) Commented Sep 19, 2012 at 18:11
  • Yeah, that would be easier. Much easier.
    – nielsonm
    Commented Sep 19, 2012 at 18:16
  • I could use some pointers, my brain melted trying to think about it. Commented Sep 19, 2012 at 18:24
  • I guess I need to know where I would find the setting for the view to read what the taxonomy for the node is. It's in a separate panel, and I'm not sure if that would work because of it. Commented Sep 19, 2012 at 18:26
0

If the preview works when you type in the tag, then you may need to switch the Filter Value Type to Term ID rather than use the term name. This is often because Pathauto settings are not the same as Drupal's internal path. Try the above change to the filter value and then check Devel on your pages, you should have a 'tid' variable that is populated with the appropriate term ID.

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.