• Resolved neverforget98

    (@neverforget98)


    This plugin (WP User Avatar) is causing this error on the front-end of my site:

    Fatal error: Call to undefined function get_current_screen() in /home/devpen/public_html/wp-content/themes/pitch/extras/settings/settings.php on line 397

    Please help. I will be disabling it until someone can help me find a solution.

    http://ww.wp.xz.cn/extend/plugins/wp-user-avatar/

Viewing 4 replies - 1 through 4 (of 4 total)
  • It seems to be a problem with the get_current_screen() function in your theme. After searching around, a quick fix seems to be to add this:

    function get_current_screen(){
      global $current_screen;
      if(!isset($current_screen)){
        return null;
      }
      return $current_screen;
    }

    at the bottom of the functions.php file in your Pitch theme folder.

    After looking into it more, adding that function might cause a “Cannot redeclare get_current_screen()” error. I’ll have to look into this problem a little further.

    I’ve included a fix for the get_current_screen function within the plugin. Please try version 1.4.2 and see if it works for you.

    Thread Starter neverforget98

    (@neverforget98)

    It worked! That’s awesome! Thank you so much! 🙂

    Brandin

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Plugin causing Fatal Error’ is closed to new replies.