PHP Bulletin Board Home
News About Home
Features of phpBB Test drive phpBB Downloads Support for phpBB The phpBB Community Styles for customising phpBB 3rd party modifications to phpBB

Support Home | Knowledge Base Home | Submit Article | Search Articles | Browse Articles
 I accidently deleted my config.php file. What do I do? 
Description: Here's the solution of this problem
Author: ZoliveR
Date: Wed Jan 22, 2003 11:27 am
Type: Info
Keywords: config,deleted,config.php
Category: Miscellanea
If you are like one of the many people who accidently delete their config.php file, you need the code. Simply place the following code in notepad and save it as config.php and upload it to your phpBB directory. Please note that you must change your mysql host, username, password, and database name.

(Note: It is now possible to regenerate the config.php file through dbinformer.php, located in the contrib/ directory. Since this is not an "official" script, support is not offered. Also, since phpBB now requires you to delete this directory before the board will work (you will recieve an error otherwise), it may not be there. If it isn't, don't fret, just keep reading. Otherwise, enter all information dbinformer asks for, and check the box "Generate a config file." That's it - hit submit, and copy and paste the code dbinformer gives you into a new config.php. --dougk_ff7)

Code:
<?php

//
// phpBB 2.x auto-generated config file
// Do not change anything in this file!
//

$dbms = "mysql";

$dbhost = "localhost";
$dbname = "dbnamehere";
$dbuser = "usernamehere";
$dbpasswd = "dbpasswordhere";

$table_prefix = "phpbb_"; 

define('PHPBB_INSTALLED', true);

?>


Please note that your table prefix may be different. Make sure you change dbms, depending on which database you use, and the dbname, dbuser, and dbpasswd. That's it! Upload to your phpBB directory.


FYI:
Your choices of values for the $dbms are:

  • MySQL 3.x
    Code:

    $dbms = "mysql";


  • MySQL 4.x
    Code:

    $dbms = "mysql4";


  • PostgreSQL 7.x
    Code:

    $dbms = "postgres";


  • MS SQL Server 7/2000
    Code:

    $dbms = "mssql";


  • MS SQL Server [ODBC]
    Code:

    $dbms = "mssql-odbc";


  • MS Access [ODBC]
    Code:

    $dbms = "msaccess";

Username: Password:
News | Features | Demo | Downloads | Support | Community | Styles | Mods | Links | Merchandise | About | Home
 © Copyright 2002 The phpBB Group.