Many phpBB modifications require changes in the forum's database to be completed before they can function properly. It is common for most of those modifications to include a file that allows these changes to be made by uploading the file to your forum and visiting the file using a web browser. For modifications that do not include such scripts, you can use the utility below to create your own version of the database updating PHP file.
To ensure that the PHP file generated works properly, please remember to format your SQL queries using the following guidelines.
Advanced Options This generator supports advanced options, including uninstall and upgrade queries, hack name, support site, and phpBB 3 module creation. Click the arrow to access these options.
If you are an advanced user or a modification author that would like to package a database update file in your downloads, this generator can create scripts with several additional features. Generated files can perform three tasks: installation, uninstallation, and upgrades from a previous modification version to a later one. When used, the files will provide options for each task if queries for that task are entered in this form. You can also enter additional information to customize the display of the final file.
If you do not already have uninstallation queries, you can click the "Attempt to parse Install SQL into Uninstall SQL" check box. The generator will try to read queries entered into the Install SQL box above and build uninstall queries from that. Only CREATE TABLE, ALTER TABLE ... ADD, and INSERT INTO phpbb_config queries are supported by this process. They will be converted to DROP TABLE, ALTER TABLE ... DROP, and DELETE FROM phpbb_config queries, respectively. Queries created this way will be executed after any additional queries you enter in the Uninstall SQL area.
Attempt to parse Install SQL into Uninstall SQL
This generator can also help with adding new modules to phpBB 3. If you need to add modules, click the arrow above to display the module options.
Modules are a little hard to install on your own. Fortunately, the generator can do the work for you. To install or uninstall modules, you must provide a path to the module's information file. An example path would be includes/acp/info/acp_ban.php. This example would tell the generator to install the admin banning module.
Learn More about how the generator works with modules. Hide Details
The information files for modules, such as those in includes/acp/info, contain lines detailing the modes that can be used to access a module. When you tell the generator to install or remove a module, it uses these lines to locate the module in the database. Here is a sample mode line from acp_ban.php (the spacing has been altered for display here).
'user' => array('title' => 'ACP_BAN_USERNAMES', 'auth' => 'acl_a_ban', 'cat' => array('ACP_USER_SECURITY')),
The modes lines also contain the menu locations where links to the module will be displayed. The "title" and "cat" entries are important. The title matches a $lang key and will be the text used to link to the module. The cat array determines which menu categories should display the link. You can have more than one entry in the cat array, like so:
'user' => array('title' => 'ACP_BAN_USERNAMES', 'auth' => 'acl_a_ban', 'cat' => array('ACP_USER_SECURITY', 'ACP_CAT_DOT_MODS')),
The phpBB developers recommend that any new admin panel pages for modifications be placed in the .MODs section of the ACP. To do this, you first have to create a category in the .MODs section. The generator can do this with a special extension to the normal mode lines, the "new_parent" directive. The "new_parent" directive consists of two parts: the title and category. These work exactly like the same parts in the mode lines. Below is a example with the "new_parent" directive in bold. If you would like to see a working example, one can be found in the IP Search download for phpBB 3 available on this site.
'new_parents' => array( array('title' => 'INSTALLED_MODS', 'cat' => array('ACP_CAT_DOT_MODS')), ), 'modes' => array( 'config' => array('title' => 'VC_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('INSTALLED_MODS')), ),
If you want to install or remove a module using this generator, it must have an info file on the server before the generator script is run.
The remaining fields are optional. If you fill them in, information related to the modification will be displayed in the installer. These fields are mainly useful for files that will be distributed with modifications. When creating a file for personal use, there is usually no need to use these.