Fatal error: Call to undefined function wp_get_current_user() in /home/…

Front Support Plugins Support WP Reviews Plugin Fatal error: Call to undefined function wp_get_current_user() in /home/…

This topic contains 10 replies, has 2 voices, and was last updated by  Hesham 2 years, 11 months ago.

  • Author
    Posts
  • #4186

    Regina Walker
    Participant

    I have WP Multisite on an addon domain and I installed wp-reviews plugin and activated. Immediately and for the first time, I got this fatal error on my Network Admin and was not able to access it at all:
    Fatal error: Call to undefined function wp_get_current_user() in /home/…
    So I deactivated one plugin at a time until all plugins on my addon domain and subdomain were deactivated… but it didn’t help.
    So I uninstalled wp-reviews plugin and that didn’t help.
    So I tried to delete the subdomain I had just created before installing the plugin (the one I had activated the plugin on) but that didn’t help.
    So now what?
    How do I get my Network Admin for Multisite back?
    Does this mean I can’t use the plugin?

  • #4187

    Hesham
    Keymaster

    Hi Regina,

    Strange! My test site is on a sub-domain name (which is not different than an addon domain), and it’s also a multi-site setup. and everything works fine.

    I need to see the full error message to understand what happened.

    To get back your dashboard access, follow these steps:

    1- Use FTP access and change the plugins directory name to something else.
    2- also change the wp-reviews folder name to something else.
    3- Login to the dashboard, and after that return the plugins directory name to “plugins” as it was before.
    4- activate your plugins one by one.

    Please, let me know the full error message.

  • #4188

    Regina Walker
    Participant

    Hi Hesham,

    Thanks for the quick reply!

    This is the full error I received.

    Fatal error: Call to undefined function wp_get_current_user() in /home/username/public_html/domain-name.com/wp-includes/capabilities.php on line 1329

    I’m going to work on your instructions for the dashboard now.

  • #4189

    Regina Walker
    Participant

    I did what you said and got my Multisite Network Admin back.
    However, all my plugins were uninstalled:
    The plugin s2member/s2member.php has been deactivated due to an error: Plugin file does not exist.
    The plugin akismet/akismet.php has been deactivated due to an error: Plugin file does not exist.
    The plugin amazon-auto-links/amazon-auto-links.php has been deactivated due to an error: Plugin file does not exist.
    The plugin bwp-google-xml-sitemaps/bwp-simple-gxs.php has been deactivated due to an error: Plugin file does not exist.
    The plugin duplicator/duplicator.php has been deactivated due to an error: Plugin file does not exist.
    The plugin nice-youtube-lite/niceYouTubeLite.php has been deactivated due to an error: Plugin file does not exist.
    The plugin related-youtube-videos/index.php has been deactivated due to an error: Plugin file does not exist.
    The plugin wordpress-seo/wp-seo.php has been deactivated due to an error: Plugin file does not exist.
    The plugin wpleadplus/index.php has been deactivated due to an error: Plugin file does not exist.

    buddypress, bbpress also no longer exist.

    I’m sure I have a recent backup thank goodness!

    Any idea what could have happened and what I should do?

  • #4190

    Hesham
    Keymaster

    This is normal, you just need to make sure the “plugins” directory is re-named back to “plugins”, then activate the plugins again one by one.

    I just checked the WP reviews plugin for that specific function that made the error, and it’s not part of the plugin, so it could be something else that breaks your site!

    Let’s get the site back, and then we will see.

  • #4191

    Regina Walker
    Participant

    YAY!!!!!!!!!!!!! Everything is fixed!!!!!!!!! hugs hugs hugs hugs!!!

  • #4192

    Hesham
    Keymaster

    Haha.. great!

    So, now I guess the WP Reviews plugin is disabled?

  • #4193

    Regina Walker
    Participant

    No, I had uninstalled previously in case it was the problem. So all I did was re-install it. All the other plugins still have to be activated.

    wp-reviews is on my new review subdomain so it’s a clean slate.

    the main domain is the one with s2member, buddypress, bbpress and all the other plugins.
    Any counsel on order of re-activation?

  • #4194

    Hesham
    Keymaster

    Not really. It should be fine.

    Let me know if you ran into trouble again.

  • #4195

    Regina Walker
    Participant

    I found out which plugin is causing the fatal error and it’s not wp-reviews. Thanks for all the help!

  • #4197

    Hesham
    Keymaster

    Glad to hear that.

The forum ‘WP Reviews Plugin’ is closed to new topics and replies.