Closed (fixed)
Project:
Acquia Marina
Version:
6.x-1.0
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
2 Oct 2008 at 05:52 UTC
Updated:
22 Oct 2008 at 11:42 UTC
I was getting this error earlier ...
Fatal error: Call to undefined function taxonomy_get_vocabularies() in /Users/overthis/Sites/icf/sites/all/themes/acquia_marina/template.php on line 339.
I temporarily resolved the problem by commenting out the Taxonomy block of the template.php file. Later, I realized that the Taxonomy module is required. Perhaps there should be a readme.txt file noting this, or the code should have its own bypass of the Taxonomy block if the Taxonomy module isn't installed.
Comments
Comment #1
wmostrey commentedI agree that although taxonomy is a core module that's enabled by default, the theme shouldn't blindly depend on it. A simple module_exists() will fix this issue.
Comment #2
netbjarne commentedsecond that - i also uninstalled this otherwise interesting looking theme due to this error
Bjarne
Comment #3
wmostrey commentedBjarne, you can simply enable the taxonomy module without configuring anything, that should make the error disappear until this is fixed.
Comment #4
stephthegeek commentedThis is a biggie that got overlooked, thanks everyone. Jwolf is on a train going cross country right now so unfortunately we won't be able to update this in CVS for a few days, but I'll post the code fix to this issue today.
Comment #5
stephthegeek commentedTo resolve, change line 338 in template.php from:
if ($taxonomy_display == 'all' || ($taxonomy_display == 'only' && $vars['page'])) {
TO:
if ((module_exists('taxonomy')) && ($taxonomy_display == 'all' || ($taxonomy_display == 'only' && $vars['page']))) {
Comment #6
wmostrey commentedWorks for me, good to go. There's no need for the first couple of extra brackets btw. This works just as fine:
if (module_exists('taxonomy') && ...Comment #7
sociotech commentedNOTE: ADDITIONAL CODE FIX FOR TAXONOMY ERROR
After a deeper review, it turns out that there is another section, this time in theme-settings.php, that needs to check for the existence of the Taxonomy module. Without this fix, Drupal will generate an error when the Taxonomy module is not enabled and an admin goes to the theme settings page for Acquia Marina (which has settings for taxonomy display).
We will be rolling this change into the next release of Acquia Marina, but in the meantime I thought I'd post the information so people who wanted to make the change themselves could try it out.
To fix this, beginning at line 338 in theme-settings.php, add an enclosing if statement that checks for the existence of the taxonomy module. Change the following:
And beginning at line 354 in theme-settings.php, complete the enclosing if statement by adding a closing bracket. Change the following:
Comment #8
jwolf commentedFixed in the 6.x-1.1 release.
Thank you!!
Comment #9
zilla commented@jwolf - you guys are all over every bug on this forum! you're awesome!
Comment #10
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.