The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
[How-To] Product Managament (vBulletin 3.5 RC 1 and up)
This How-To is mainly meant for Hack-Developers, if you are only planning to use Hacks just read the End-User section. Developers vBulletin 3.5.0 RC1 introduces a new concept for customizing/modifying vBulletin: Products. With Products, you can manage Plugins, Phrases, Settings and Templates in just one XML File. Furthermore it supports Install/Uninstall Codes (for running queries, etc.), it also covers updating existing Hacks as you can add Codes for different Versions. To start, you first have to turn on debug mode: Put PHP Code:
Then go to ACP / Plugin System / Manage Products. Click Add/Import Product. In the second Form (Add New Product) fill in the Details for your Hack:
Afterwards, create all the Plugins, Phrases, Templates and Settings your Hack requires and make sure you select the Product you just created. Important: Templates must be placed in the MASTER Style, Phrases in the MASTER Language When you are finished, go to ACP / Plugin System / Manage Products and select Edit from the Dropdown next to your Product. In the Form (Add New Install/Uninstall Code) add all Code necessary to install/uninstall your Hack (eg, Queries, etc.). If you are updating an existing Hack, add new Install/Uninstall Codes for the new Version that just make the changes necessary to upgrade the previous Version; Product Management will make sure that all necessary Codes will be run. If your Hack includes Usergroup Permissions/Bitfields, add the following Code to Install and Uninstall to rebuild the Bitfield cache: PHP Code:
End-Users Go to ACP / Plugin System / Manage Products. Click Add/Import Product, select the product XML File for the Hack you want to install. If you are upgrading an existing Hack, make sure that Allow Overwrite is set to Yes This How-To is (C) 2005 by KirbyDE and you are not allowed to redistribute it in any way without my explicit consent. |
#72
|
||||
|
||||
The Code should be
PHP Code:
|
#73
|
|||
|
|||
Don't use the last underscore.
|
#74
|
|||
|
|||
Quote:
In review, just to make sure I have the process down: 1) Enable debug mode. 2) Enable plugin system. 3) Add your product using the manager. 4) Create custom setting groups. 5) Create custom settings. 6) Create custom phrasegroups. - A) SELECT MAX(phrasetypeid) + 1 AS newid FROM phrasetype WHERE phrasetypeid < 1000 - B) INSERT INTO phrasetype (phrasetypeid, ...) VALUES ('$newid', ...) - C) ALTER TABLE language ADD phrasegroup_whatever MEDIUMTEXT NOT NULL - D) Rebuild languages 7) Create custom phrases. 8) Create custom templates beginning with a unique prefix in lowercase, such as poduct_name. 9) Tweak existing templates if needed. 10) Create the $only['product_name'] = 'Product Name'; plugin for your product using the template_groups hook. 11) Create any other hooks plugins your product needs. 12) Write new files. 13) Hack old files if needed. 14) Export your product to xml. 15) Package it with a small script to install the tables and explain manual tweaking of existing templates and files. Done. Right? |
#75
|
|||
|
|||
Installation of new tables can be handled from the Product Manager, no need for installation scripts.
|
#76
|
||||
|
||||
@Albus
That's it - yes. But as Marco already pointed out, creating/altering tables can (and should be) handeled with product install/uninstall codes. Also there is a function to create custom phrasetypes: add_phrase_type() in adminfunctions_language.php Just the GUI is missing I pointed this out @ .com, but the Devs don't seem to see a need for it. For my needs, I ported this Hack - makes it easy to handle Phrasegroups I've contacted the author if he plans to release it, but did not get a reply so far. |
#77
|
|||
|
|||
Quote:
1) How does the version number affect rollbacks to a previous version, should the user wish to do so? I realize that you'd have two install codes and two uninstall codes. 2) How does this affect the order the product is installed in? In other words, what's the order of things? Install code, settings, phrases, templates, etc... Sorry for the all the questions, but I want to make absolutely sure I know what I'm doing. One more thing...is the 'vb' product name prefix still in effect? If so, how do things like vbadvanced name their products? I ask because I recently registered a development domain that starts with vb and would like my products to bear that prefix. |
#78
|
||||
|
||||
Once you've created a product XML you don't have to take care of phrase and phrasetype stuff, vBulletin will handle that itself.
I was only babbling about initially creating the phrasgroup on your developement machine. A rollback is not possible (yet?), the User can only uninstall. Installation order is - Install-Code - Templates - Plugins - Phrases - Settings On uninstall, uninstall codes will be called in reversed order (og. newest version first). Prefix vb is reserved for Jelsoft use, yes. |
#79
|
|||
|
|||
Quote:
|
#80
|
||||
|
||||
Where is writing the actual XML for a product covered?
|
#81
|
||||
|
||||
Quote:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|