Closed (works as designed)
Project:
Taxonomy display
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
11 Nov 2012 at 12:54 UTC
Updated:
23 Dec 2015 at 21:31 UTC
Jump to comment: Most recent
Comments
Comment #0.0
1mundus commentedtypo
Comment #1
damienmckennaThis is a problem stemming from the fact that you're using Taxonomy Display to create custom versions of taxonomy term pages - it isn't that you're using a module to do the display, but rather that the internal paths have changed so that the logic in Metatags no longer matches.
I suggest, for now, to use the Metatag Context submodule to handle it.
Comment #2
1mundus commentedThank you for the explanation.
I have installed context and context submodule and am trying to set it up properly. However, it seems a bit tricky.
1. If you just use the path, it works perfectly (e. g. blogs*)
2. The first condition is not enough, because it displays these meta tags for nodes in that vocabulary too. The workaround can be to add another context that checks if it is a node of a certain type and then you overwrite the first context, but that slows the loading down and is additional context to maintain.
3. I would rather just check if it is the term page of a certain vocabulary and then assign it the necessary meta tags. Unfortunately, when I choose "Taxonomy term" condition and choose e. g. "Blog" as the vocabulary that I want to affect, nothing happens.
Comment #3
1mundus commentedChoosing the view as the context doesn't help either.
Comment #4
damienmckennaAt this point I don't think Metatag should need to handle every possible scenario - if there isn't a simple & generic way of handling this using the data from entity_get_info() then the other module, i.e. Taxonomy Display, should do the integration.
Comment #5
1mundus commentedYou're right.
I ended up avoiding Taxonomy Display and using Views. If someone will want to do it too:
1. Add content view
2. Add "Content: Has taxonomy term ID (with depth)" contextual filter
3. Add the desired number of BLOCKS
4. In the contextual filter settings first set "Provide default value" to Taxonomy term ID from URL. Enable Taxonomy Term validator and choose the vocabulary for each view block that you will create
5. Add necessary fields
6. Now you have different blocks enabled for different vocabularies. However, there is still the default taxonomy term display activated. You will get rid of it by enabling Taxonomy Term view (it's a default view, you just need to enable it). That view overrides taxonomy/term/% path. If you display taxonomy term content in a block, you will probably want this view to be empty. Just add Global: Custom text field and leave it empty.
Maybe this isn't the cleanest and best way, but meta tags are now displayed normally and you use one module less, which can be good for performance and ease the maintenance.
Damien, thank you for your dedication to this module and the whole Drupal project!
Comment #6
damienmckenna@1mundus: Thanks, I appreciate it :)
Comment #7
vasyok commented#5 not work with exposed filters
Sometimes help using AJAX in views
Comment #8
damienmckennaLets move this over to Taxonomy Display to be fixed over there.
Comment #8.0
damienmckennaAdded 2 steps to reproduce
Comment #9
VanD commentedThis is still an issue, taxonomy display will not show the settings set by the metatag module.
Comment #10
juggler39 commentedI have the similar problem. The metatags 'description' and 'keywords' don't show if the handler for Term display is set to 'hidden'. If it is set to 'core', the metatags are on the page.
Comment #11
dgastudio commentedany update?
Comment #12
dgastudio commentedfix:
1. change term display to core
2. add
function themename_preprocess_page(&$vars) {
if (arg(0) == 'taxonomy' && arg(1) == 'term' && is_numeric(arg(2))) {
unset($vars['page']['content']['system_main']['term_heading']);
}
}
Comment #13
juggler39 commentedKervi, thank you for your solution. It works.