[3.5] Can't login anymore due to a plugin? Unplug your vBulletin!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Floris
    Senior Member
    • Dec 2001
    • 37767

    [3.5] Can't login anymore due to a plugin? Unplug your vBulletin!

    Note: This works only on vBulletin version 3.5.0

    All you need to do to workaround a broken plugin that prevents you from logging in etc. is to edit config.php and add this code immediate after the first line saying '<?php':
    PHP Code:
    define('DISABLE_HOOKS'true); 
    This will totally disable hooks and plugins until removed, so you should be back to the default vBulletin code.
    Last edited by Marco van Herwaarden; Sun 30 Jul '06, 9:40am.
  • Biker
    Senior Member
    • Oct 2003
    • 1261
    • 4.0.0

    #2
    Thanks Floris. Hopefully I'll never need it, but I've got that bugger saved just in case.


    Edit -- This should be a sticky, too.
    Last edited by Biker; Sun 24 Jul '05, 7:01pm.
    I drank WHAT?! - Socrates

    Comment

    • Floris
      Senior Member
      • Dec 2001
      • 37767

      #3
      If it turns out that we get a lot of support tickets because of people rendering their forums unaccessable due to a plugin install and require to unplug the plugin system, I will suggest this to be included in future tools.php

      Comment

      • Psionic Vision
        Senior Member
        • May 2005
        • 202
        • 3.6.x

        #4
        If it turns out that we get a lot of support tickets because of people rendering their forums unaccessable due to a plugin install and require to unplug the plugin system, I will suggest this to be included in future tools.php
        If that file is ever included into tools, its code should be cleaned up a bit. How about also making a version where you could click a button to enable/disable the hooks?

        Comment

        • Mike Sullivan
          Former vBulletin Developer
          • Apr 2000
          • 13327
          • 3.6.x

          #5
          Alternatively, you can just put this into your config.php:
          Code:
          define('DISABLE_HOOKS', true);
          Login to the control panel, fix the problem, and then simply remove the line.

          Comment

          • Psionic Vision
            Senior Member
            • May 2005
            • 202
            • 3.6.x

            #6
            Here is my updated version

            CHANGES:

            + An option to turn the plugins on or off...
            + Cleaner and more valid HTML and the code itself...
            Attached Files
            Last edited by Psionic Vision; Mon 28 Nov '05, 3:48pm.

            Comment

            • Mr_Butter
              Senior Member
              • Apr 2005
              • 1178

              #7
              *rolls eyes*


              as long as it gets the job done....

              Comment

              • Floris
                Senior Member
                • Dec 2001
                • 37767

                #8
                All great tips!

                Comment

                • Andreas
                  Senior Member
                  • Feb 2004
                  • 2323

                  #9
                  Nice Script, but doesn't always work.

                  Put
                  PHP Code:
                  die; 
                  in Hook fetch_userinfo and BANG - only Mike's suggestion works.

                  Comment

                  • Psionic Vision
                    Senior Member
                    • May 2005
                    • 202
                    • 3.6.x

                    #10
                    Why would you want to put "die;" in that hook? That would be really lame

                    Comment

                    • Psionic Vision
                      Senior Member
                      • May 2005
                      • 202
                      • 3.6.x

                      #11
                      Solution:

                      In deplug.php,

                      FIND

                      PHP Code:
                      define('THIS_SCRIPT''deplug'); 
                      ADD UNDERNEATH

                      PHP Code:
                      define('DISABLE_HOOKS'true); 
                      There you go - a working-in-all-occasions script.

                      Comment

                      • hostthebest
                        New Member
                        • Apr 2005
                        • 11
                        • 3.5.0 Pre-Release

                        #12
                        I got this alot on the member area
                        Host The Best - sales (at) hostthebest.com
                        VPN Service | WHMCS Addons / Modules

                        Comment

                        • Matt Hinton
                          New Member
                          • Jun 2005
                          • 8

                          #13
                          Originally posted by Floris
                          There are times when users enhance their board with a plugin, but incorrectly or it is coded incorrectly, and make an oopsy, resulting in getting being unable to login to their admincp/ anymore, or even can't login at all anymore. Running this script will 'unplug' the global 'use plugin system' and rebuild the settings in an attempt to fix that.

                          Instructions: Download the script and upload it to your web site, put it in the installed forum directory. Then point your browser to the file and let it run. Hopefully if everything goes ok you can login to your site and admincp/ again. For security reasons please remove the file again from your web site if you no longer need it.

                          Note: This script works only on vBulletin version 3.5.0
                          I'm currently having this problem. i've uploaded that file into username/public_html/forums , i then ran the file and it says:

                          [FONT='Courier New', Courier, mono]Updating: enablehooks to 'no', turning it off[/FONT]

                          Fatal error: Call to a member function on a non-object in /home/dnadmin/public_html/forums/unplug.php on line 33

                          I then remove the script and try to login the admincp once more and it says logging in please wait, but then just sends me back to the original admin login page. Please help me.

                          Comment

                          • Floris
                            Senior Member
                            • Dec 2001
                            • 37767

                            #14
                            Even with the tweak from two posts above?

                            Comment

                            • Matt Hinton
                              New Member
                              • Jun 2005
                              • 8

                              #15
                              Originally posted by Floris
                              Even with the tweak from two posts above?
                              I've tried the depug.php file and enabled it, and it still doesnt let me logon.

                              Comment

                              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                              Working...