Closed (fixed)
Project:
Block Visibility by Term
Version:
7.x-1.0-alpha1
Component:
User interface
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
16 Oct 2011 at 20:32 UTC
Updated:
23 Jul 2012 at 20:51 UTC
When I configure a block using a Content Type, all is well. Thus I can choose the Content Type of Events and the block appears on every Events page.
However, I want the block to appear just on the Classes pages, which is one of several Event Types (set up that way in Taxonomy). When I choose Classes under the Terms area, the block does not appear anywhere. This is true whether or not I also choose the Content Type of Events.
The Terms area correctly has a list with checkboxes for all of the various subtypes that I have set up in Taxonomy, but it just doesn't work when I check one. Any ideas?
Comments
Comment #1
karnal69 commentedI'm having the same issue, the only difference being it's happening with the generic Basic Page content, rather than a custom content type.
When having no restrictions on block visibility, it shows on every page. But when I try and set it to be only visible on pages tagged with the term 'Products', it does not show on any page, even those which have the term 'Products'.
Let me know if you need any more information.
Comment #2
marcvangendThanks for your bug reports. I have been thinking hard, but I don't know yet what might be causing this. Can one (or both) of you provide the steps to reproduce your error on a clean Drupal 7 installation? Thanks.
Comment #3
HTF commentedI have just noticed that the block is only visible if the language is set to neutral, it disappears when the language is set to English, could this be related to the problem above?
Comment #4
marcvangendBob3009: yes, that could be the cause. As said, I'd love to know exactly how I can reproduce the error.
Comment #5
HTF commentedThis error happened whilst using Drupal 7.8 and Block Visibility by term 7.x-1.0-alpha1. When I create an article and tag it with a term and use langauge neutral the block appears. If I change the article to English and re-save, the block disappears.
Comment #6
dialn commentedIt's the same block apareceen not any page when using taxonomy terms of this failing is not that I'm using pathauto in taxonomies, please help someone who has solved this problem
Comment #7
rv0 commentedField language ≠ node language.
A language neutral taxonomy (default) and a localized node (in my case, dutch, NL) is what you need to reproduce this problem.
The error occors because you try to get the tid using the node language as an array key. While the tid is actually "und".
A workaround is to use field_get_item().
I've rewritten the relevant part in block_term_block_list_alter:
After this change module will work just fine.
Comment #8
rv0 commentedChanging title for clarity.
Comment #9
andrés chandía commentedThanks a lot, it works for me
Comment #10
komlenic commentedChange added to development branch... thanks rv0!