WordPress.org

Support

Support » Plugins and Hacks » BackWPup - WordPress Backup Plugin » [Resolved] Fatal error: Call to undefined method stdClass::add_role(In)

[Resolved] Fatal error: Call to undefined method stdClass::add_role(In)

  • Unfortunately I don’t know the version of Word Press other than I know it’s not current. I was trying install/update BackWPup so I could back up the our blog before installing the new WP update, but now when ever you try to access the blog or log into WP you get the following error:

    Fatal error: Call to undefined method stdClass::add_role() in /home/content/x/p/e/xpertmortgage/html/wordpress/wp-content/plugins/backwpup/inc/class-install.php on line 94

    In another forum entry mentioned that there is a file in your blog directory called wp-includes/version.php which contains the version of WP installed … however I don’t see this file in this directory.

    Any suggestions on fixing the problem with the plug-in or simply removing the plug-in so the blog is back on line & I can log-in to WP would be appreciated.

    Mike

    http://wordpress.org/extend/plugins/backwpup/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi mrusheleau have a read at this thread, it will help you with your issue.

    Kind regards

    Thanks mbrsolution … but I’m still not clear what needs to be done since alot of that thread is dealing with adminstration rights issues. Given that I know I’m using an older version (even though I can’t idenify what version unless), is the work around the following?

    Replace the following code in the backwpup > inc > class-install.php file:

    get_users( array( ‘blog_id’ => 1, ‘role’ => ‘administrator’ ) );

    with:

    get_users( array( ‘blog_id’ => 1, ‘role’ => ‘administrator’, ‘fields’ => ‘all_with_meta’ ) );

    Sorry not that technical and just want to make sure I understand the work around.

    Thanks, Mike

    Tried this fix and it worked! Thank you.

    Plugin Author Robert Windisch

    @nullbyte

    Hi mrusheleau,

    the fix will make WordPress get the WP_User object that we can add the right to access the BackWPup admin page for to all admin users. Current versions of WordPress will give us the WP_User class by default. We will fix that in the next version.

    regards,
    Robert

    Hi, I get this error in a WP 3.5.1 running under Windows Server:

    PHP Fatal error: Call to undefined method stdClass::add_role() in E:\home\vitaderm\web\wp-content\plugins\backwpup\inc\class-install.php on line 94

    The plugin had to be manually erased from the FTP because both admin pages and public webpages were blank and showin the above error. The plugin was deleted in those websites.

    Plugin Author Robert Windisch

    @nullbyte

    Hi Marcelo,

    please do the changes on the class-install.php of our plugin. We fix this with the next release of our plugin.

    regards,
    Robert

    ok, I’ll wait for you to submit the new version of the script. I will stop updating it until the bugs are the lesser possible.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Resolved] Fatal error: Call to undefined method stdClass::add_role(In)’ is closed to new replies.
Skip to toolbar