Heiko Mamerow
Member
Posted 3 months ago #
Hi Sergej,
thank You for this great plugin!!!
It is running wonderful on my localhost-wp-install, but on my webserver it will not run.
After install, when i click somewhere (e.g. "activate the plugin" or elsewhere...), it comes to this error-message:
Fatal error: Call to undefined function get_current_screen() in /home/www/wordpress/wp-content/plugins/snitch/inc/snitch_cpt.class.php on line 275
My php-knowledge is not good enough to fix it.
http://wordpress.org/extend/plugins/snitch/
Heiko Mamerow
Member
Posted 3 months ago #
I found a workaround:
I just delete something in line 275 and then the plugin is running fine.
old line 275: (bring the error)
if ( empty(get_current_screen()->id) OR get_current_screen()->id !== 'edit-snitch' OR empty($_GET['snitch_state_filter']) ) {
new line 275: (working fine)
if ( empty($_GET['snitch_state_filter']) ) {
But beware: i dont know exact what i do. I just play a little bit... ;-)
Sergej Müller
Member
Plugin Author
Posted 3 months ago #
I'd suggest to just abort if WP_INSTALLING or WP_INSTALLING_NETWORK is defined and true.