Configuring Debug Mode


  • Configuring Debug Mode

    Debug mode is useful for development purposes- it is required if you will be creating VB5 Modifications you intend to distribute for others to download. However it is also useful for trouble-shooting issues with your site as debug mode often provides more specific error messages when something goes wrong- as such if you are having trouble support will often ask you to put your site into debug mode.

    Debug mode requires two small file edits in vBulletin 5. This is because VB5 has two config.php files by design. Both files require an edit and it is a little different for each.

    Please note- before editing any PHP files be sure you have a real code/text editor. The built in Windows Notepad should never be used to edit PHP files- Windows Notepad can often add invisible characters to code files that will cause errors once your re-upload the edited files. Windows users should instead download one of the many free alternatives. Two popular free text editors for Windows (all versions) are:

    Notepad2 - Available from Flo's Freeware - Looks almost exactly like regular Notepad, Native 32bit and 64bit versions.
    Notepad++ - Available from - A little more advanced than Notepad2

    I am not aware of any problems with the built in text editors in Max OSX or Linux but there are plenty of advanced free editors available for all systems.

    Once you have your text editor setup the first edit is to your front-end or "Presentation" config,php file. This is the one in your forum-root directory.

    Download this file from your server and open it in a text editor. Look for the line that says:
    PHP Code:
    $config['debug'] = false

    Here is a screenshot from the VB 5.0.5 config.php file-
    Click image for larger version

Views:	0
Size:	65.0 KB
ID:	4460788

    Edit the line to say:

    PHP Code:
    $config['debug'] = true
    Then save the file and re-upload it to your server overwriting the existing file.

    Test your site- make sure it loads- it should- if you run into any problem simply re-copy the original config.php file from the original VB Install package and overwrite it, but it is very unlikely you will have an issue.

    Now we must make the 2nd edit. This edit is to the back-end or "core" config.php file which is in your /core/includes/ directory.

    This file contains a lot of important information for your database which is not as easily replaced as the front-end file should something go wrong, so please save a back-up of this file somewhere else on your computer before editing the original file.

    Download a copy of this file and find the line that says

    PHP Code:
    // $config['Misc']['debug'] = true; 
    This is toward the end of the file, below is a screenshot-

    Edit the line to remove the two slashes // at the front and then re-save and re-upload the file.

    PHP Code:
    $config['Misc']['debug'] = true
    Now check your site one more time- it should both be working and be in debug mode.

    You will know it is in debug mode when there is a bunch of extra information shown below pages on the front end- example:

    Debug mode in the back-end (Admin CP) is a little less noticeable. There will be several new/more options mostly for those developing their own modifications. One way to tell is to go to Admin CP -> Style Manager and you will now see the "Master Style" visible above all other styles as below:

    If you see these changes you have confirmed you are in debug mode.

    To disable debug mode you basically reverse the above, edit each file and undo the changes.

    Note- if in either of the above files you can't find the text I say to look for you can safely simply add the line $config['debug'] = true; to the front-end/presentation file or $config['Misc']['debug'] = true; to the back-end/core file and that will work as well. Add it at the very top, just below the first line of the file which should be <?php.

    To undo the above changes simply comment out the line by adding two slashes // at the start of the line so it will be ignored as if it didn't exist. This way should you need to enable it again you just have to remove those slashes.

    • BirdOPrey5
      BirdOPrey5 commented
      Editing a comment
      vBcloud users should create a support ticket and support staff can enter debug mode themselves to check the issue.

    • avitor
      avitor commented
      Editing a comment
      thanks for this help

    • Craig
      Craig commented
      Editing a comment
      Please add to /articles/vbulletin-5-connect-aa/vbulletin-5-tutorials
    Posting comments is disabled.

About the Author


BirdOPrey5 The details of my life are quite inconsequential... Find out more about BirdOPrey5

Article Tags


administration (1) beginner (3) channels (1) cloud (1) connect (1) Custom (1) Google (1) how to (1) howto (1) https (1) Intermediate (2) MYSQL (1) passwords (1) recovery tools (1) security (2) seo (1) sftp (1) ssl (1) ssl certificate (1) style (1) tls (1) tutorial (2) users (1) vb5howto (5) vbcloud (1)

Latest Articles


  • Changing your site's favicon
    by Wayne Luke
    The favicon allows you to extend your brand identity to the browser tab. This can often be the only thing a user sees if they have many tabs open. The favicon is a special 16 X 16 icon that the browser automatically looks for in the root directory of your site. vBulletin also ships with one in its root directory. If vBulletin is installed in the root directory of your site, you can overwrite the provided icon to change it for your users. However, you will need to remember to do this with every version...
    Tue 21 Nov '23, 11:39am
  • About .htaccess
    by Wayne Luke
    .htaccess is a configuration file for the Apache Web Server. It allows you to customize how your server works. Depending on how your hosting provider has the server configured, you can redirect people to different locations, secure directories and files, tell browsers how long to cache files, update PHP variables, and more. vBulletin comes with a pretty extensive .htaccess file that does a these things for you. Location vBulletin comes with a file named htaccess.txt in the original download. When ...
    Mon 11 Sep '23, 12:57pm
  • Answered Topics
    by Mark.B
    In vBulletin 5.6.5, we added a new feature - Answered Topics.

    Topics can now be marked as "Answered." This is a special status applied to a specific post within the topic. The post that is marked as the Answer will be highlighted and show directly under the starting post in the topic.

    The ability to mark posts as the Answer in a topic is controlled by permissions. There are three different permissions to control this.
    Usergroup and Channel Permissions both...
    Sun 8 Jan '23, 12:43pm
  • Custom Node Fields
    by Mark.B

    In 5.7.2, we have added a new feature - Custom Node fields.

    This new feature allows Administrators to define text and text area fields that are assigned to channels (eg forums).
    When a user creates a new topic, defined custom node fields will be available.
    1. The Administrator will create Field Categories in the AdminCP. Each category is assigned to one or more channels.
    2. Within each category, the Administrator can create one or more fields that will get assigned
    Thu 29 Dec '22, 3:19am
  • Using User Ranks
    by Wayne Luke

    User ranks allow the administrator to set up image and HTML rewards for their users once they reach specific goals. In versions before vBulletin Connect 5.7.1, ranks could only be triggered by the number of posts and the usergroups assigned to the user. In vBulletin Connect 5.7.1, User Ranks have been expanded to allow more flexibility in creating individual ranks. Now you can build combinations of different criteria to create unique ranks for your site.

    ‚Äč Ranks can be created using th...
    Tue 25 Oct '22, 1:04pm
  • Excluding Custom Files from Suspect File Diagnostic
    by Wayne Luke
    If you have custom files, you can create an md5 sums for your smilie directory if you want. Inside the /do_not_upload folder of your download package is a checksum sub-folder. That will create custom md5_sums files.
    1. Copy the included sample_checksum_config.php file to smilies_config.php.
    2. Enter in your forum root.
    3. Give it a product id like 'smilies'.
    4. Delete the existing directories and files in the scanpaths.
    5. Add in '/core/images/smilies', under the directories comment.
    6. Run the command
    Mon 24 Aug '20, 9:48am