since the warning message is not directly pointing to EM maybe you can try the following steps to narrow down the problem:
– deactivating all other plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).
– switching to the default theme to rule out any theme-specific problems
OK, I will try that. I thought it was related to EM – are you sure it’s not?
That error relates to WordPress roles and capabilities, which could be caused by any plugin or theme. Angelo’s suggestion will help you to narrow down which.
Thanks
Thanks…
I narrowed it down to the Events Manager plugin!
I’ve updated EM to the latest version 5.5.2, and updated to WP 3.8.1.
My host is running PHP 5.4.23
This error occurs when I load a page:
Warning: Creating default object from empty value in /wp-includes/capabilities.php on line 641
This additional error occurs when I change any settings in the back end, and prevents the page from loading:
Warning: Cannot modify header information – headers already sent by (output started at /wp-includes/capabilities.php:641) in /wp-includes/pluggable.php on line 876
Any help would be appreciated!
I have installed an exact copy of the site on my local host using MAMP, and I do not get the error.
Which PHP version are you using with MAMP?
So would you say the PHP version is the only difference between the two installs? Or do you have something different in the user setup?
I can’t find any other difference. There are bound to be some other server side minor differences, they can’t be identical.
Have you tried to temporarily:
– deactivating all other plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).
– switching to the default theme to rule out any theme-specific problems
I did deactivate the plugins and as mentioned above, the events plugin is what causes the problem. I have the same theme on my local installation, and it causes no problems.
It’s a hassle to switch themes, as I have to replace all my widgets and menu settings manually. Because of the php errors, I can’t download my theme settings files either.
I have got my host to put this in the PHP settings:
display_errors = Off
display_startup_errors = Off
Can you advise whether this is a good idea? Seeing as I can’t solve it any other way, I’m stuck with this solution.
Yep, that’s an adequate solution.
Cheers