Closed AlwynBarry closed 8 years ago
Can you edit that file /home/sites/streetbaptist.co.uk/public_html/wp-content/plugins/gantry5/src/classes/Gantry/WordPress/Integration/BuddyPress/Assignments.php
and on line 33 change is_plugin_active
with \is_plugin_active
(note the back slash at the beginning).
Does it solve the issue?
Also, this this line could maybe make a problem too: https://github.com/gantry/gantry5/blob/develop/src/platforms/wordpress/WordPress/Integration/BuddyPress/Assignments.php#L212
(not related to this particular issue)
Probably also the line above? \buddypress()
. I don't have a setup with buddypress, can anyone test?
Me neither, I just took a quick look at the code
Changed line 33 to: $this->_active = \is_plugin_active('buddypress/bp-loader.php');
still:
Fatal error: Call to undefined function is_plugin_active() in /home/sites/streetbaptist.co.uk/public_html/wp-content/plugins/gantry5/src/classes/Gantry/WordPress/Integration/BuddyPress/Assignments.php on line 33
You might need to clear cache also
Cleared the cache before the test ... already had the cache plugin turned off, but cleared that anyway, and also cleared the theme cache (Rockettheme Isotope).
WP-Cache (0KB)
0 Cached Pages
0 Expired Pages
WP-Super-Cache (0KB)
0 Cached Pages
0 Expired Pages
Ok, so adding: include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
as directed in: https://developer.wordpress.org/reference/functions/is_plugin_active/
sorts the problem. But this might just be a 'quick hack' solution. I don't know the code tree and so can't see where this include should come!
That's actually what I just tried as well. I'm just not sure why it stopped working, definitely requires further investigation.
Thanks
That's very odd, I have all debugs enabled and all was working fine for me.
Error reported when WP_DEBUG true:
Works fine when Buddypress plugin is disabled ... but hardly useful in a BuddyPress site!!