Closed (won't fix)
Project:
Acquia Marina
Version:
6.x-1.9
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Issue tags:
Reporter:
Created:
17 Jun 2009 at 12:29 UTC
Updated:
2 Feb 2010 at 15:04 UTC
Modifications to taxonomy display settings in template.php don't appear to accommodate vocabulary name and term translations. Commenting the taxonomy section of template.php restores normal taxonomy translation functions. Either more documentation or a patch to template.php would be appreciated. Thanks.
Comments
Comment #1
jwolf commentedThanks. We'll look into this.
Comment #2
jwolf commented@crawleyde - Just so we understand, could you post exactly what you commented out that restores normal taxonomy translation functions?
Comment #3
crawleyde commentedSorry for the delay. I took out the whole taxonomy section in template.php:
// Taxonomy
$taxonomy_content_type = (theme_get_setting('taxonomy_enable_content_type') == 1) ? $vars['node']->type : 'default';
$taxonomy_display = theme_get_setting('taxonomy_display_'. $taxonomy_content_type);
$taxonomy_format = theme_get_setting('taxonomy_format_'. $taxonomy_content_type);
if ((module_exists('taxonomy')) && ($taxonomy_display == 'all' || ($taxonomy_display == 'only' && $vars['page']))) {
$vocabularies = taxonomy_get_vocabularies($vars['node']->type);
$output = '';
$term_delimiter = ', ';
foreach ($vocabularies as $vocabulary) {
if (theme_get_setting('taxonomy_vocab_hide_'. $taxonomy_content_type .'_'. $vocabulary->vid) != 1) {
$terms = taxonomy_node_get_terms_by_vocabulary($vars['node'], $vocabulary->vid);
if ($terms) {
$term_items = '';
foreach ($terms as $term) { // Build vocabulary term items
$term_link = l($term->name, taxonomy_term_path($term), array('attributes' => array('rel' => 'tag', 'title' => strip_tags($term->description))));
$term_items .= '
';
}
if ($taxonomy_format == 'vocab') { // Add vocabulary labels if separate
$output .= '
';
$output .= substr_replace($term_items, '
', -(strlen($term_delimiter) + 5)) .'
';
}
else {
$output .= $term_items;
}
}
}
}
if ($output != '') {
$output = ($taxonomy_format == 'list') ? substr_replace($output, '
', -(strlen($term_delimiter) + 5)) : $output;
$output = '
'. $output .'
';
}
$vars['terms'] = $output;
}
else {
$vars['terms'] = '';
}
Comment #4
GN commentedThank you -- I ran into the same problem when using the waffles theme based on Acquia Marina, and I found that commenting out the taxonomy section in template.php also fixed it.
Also, there is one more waffles bug which I guess may be relevant for Acquia Marina, too -- see
http://drupal.org/node/538108
(in a multilingual site, the site title and logo are linked to the default language front page instead of the current language front page)
it can be fixed by linking in page.tpl.php logo and title to check_url($front_page) instead of $base_path.
I'm not submitting this second issue as I don't have Acquia Marina installed and haven't checked it - at this point, it's just an educated guess :).
Comment #5
jwolf commentedWe're in the process of porting the Acquia themes over to our new theme system, Fusion.
With the release of Fusion, we will no longer have theme settings which duplicate the functionality of contrib modules.
Therefore, we are unable to dedicate resources to fixing this in the 1.x branch since Fusion will solve this.
You can read more about Fusion at:
TNT 2.0 and the future of Drupal themes with Fusion
http://www.topnotchthemes.com/blog/090709/tnt-2-0-and-future-drupal-them...
Top Notch Themes pre-releases a landmark theme called Fusion
http://chrisshattuck.com/blog/top-notch-themes-pre-releases-landmark-the...
Comment #6
hlykos commentedChange the 378 line in template.php in Acquia Marina from
$terms = taxonomy_node_get_terms_by_vocabulary($vars['node'], $vocabulary->vid);
to
$terms = i18ntaxonomy_localize_terms (taxonomy_node_get_terms_by_vocabulary($vars['node'], $vocabulary->vid));
Comment #7
GN commentedThank you, it seems to work for me.
Comment #8
tomsm commentedThanks a lot! I was trying to solve this issue for months.