Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
i get Fatal error: Call to undefined function ctools_menu_primary_local_tasks() after installing fb. but it only happen when i'm not logged in.
i'm using zen theme. I'm not sure if this is fb or zen issue.
Regards,
Reynaldi
Comment | File | Size | Author |
---|---|---|---|
#8 | Zen_ctools_include-772488-8.patch | 418 bytes | halstead |
#3 | ctools_include.patch | 394 bytes | andreiashu |
Comments
Comment #1
Dave Cohen CreditAttribution: Dave Cohen commentedThat's not a function called by modules/fb/...
possibly a bug in ctools???
Comment #2
andreiashu CreditAttribution: andreiashu commentedI think this is a ZEN bug. I get this error without having FB module installed but I'm using a ZEN subtheme.
Also the actual error looks like this:
Fatal error: Call to undefined function ctools_menu_primary_local_tasks() in /var/www/mysite/sites/mytheme/themes/zen/template.php on line 190
I'm using ZEN-6.x-2.x-dev 2010-Feb-08 snapshot.
@reynaldio can you please confirm what version are you using?
Of course the simplest workaround would be to to include the 'ctools/icludes/menu.inc' file where this function resides.
Comment #3
andreiashu CreditAttribution: andreiashu commentedAnd here is a patch. I used
ctools_include
function to do the include for us.It seems to be fixing the bug. Can anyone else confirm this?
The patch is against the latest 2.x dev snapshot.
Comment #4
andreiashu CreditAttribution: andreiashu commentedComment #5
JohnAlbinI <3 patches. :-)
Thanks! You're in the CHANGELOG now!
Comment #6
andreiashu CreditAttribution: andreiashu commentedHi John,
Thanks for including me in the CHANGELOG :-)
Comment #8
halstead CreditAttribution: halstead commentedI just got around to updating a site from 6.x-1.1 to 6.x-1.2 and this error showed up for anonymous users. The patch in #3 fixed it right away. It would be neat if it could be included in the 6.x-1.x branch for people that are still using it.
Fatal error: Call to undefined function ctools_menu_primary_local_tasks() in /var/www/drupal/sites/all/themes/zen/zen/template.php on line 103
I've re-rolled the patch in case that helps.
Comment #9
Todd Nienkerk CreditAttribution: Todd Nienkerk commentedI've confirmed that this bug is still active in 6.x-1.x. Applying the patch in #8 patch fixes it.
Comment #10
Todd Nienkerk CreditAttribution: Todd Nienkerk commentedComment #11
alexmoreno CreditAttribution: alexmoreno commentedconfirmed too, patch #8 works fine
Comment #12
JohnAlbinCommitted!
(Finally!)
Comment #14
jive01 CreditAttribution: jive01 commentedunfortunately this patch does not work for me upgrading from zen 1.1 to 1.2... If I comment out the functions, the white screen discontinues, but uncommenting the functions with the new patch still gives me the apache error.
// CTools requires a different set of local task functions.
if (module_exists('ctools')) {
ctools_include('menu');
// $primary = ctools_menu_primary_local_tasks();
// $secondary = ctools_menu_secondary_local_tasks();
}
else {
// $primary = menu_primary_local_tasks();
// $secondary = menu_secondary_local_tasks();
}
Comment #15
jive01 CreditAttribution: jive01 commentedI got this resolved. The site showed Chaos tools as up to date, yet it was not.
Comment #16
jive01 CreditAttribution: jive01 commentedI got this resolved. The site showed Chaos tools as up to date, yet it was not.