vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   Creating a Product - process ? (https://vborg.vbsupport.ru/showthread.php?t=233571)

saajjj 01-19-2010 08:46 PM

Creating a Product - process ?
 
Hello,
I want to release a product which adds a custom vB powered page to the navbar. I can't seem to figure out how some parts of the XML file are made.

The following is what I've got right now and needs to go into the product:
  • 1x Query to create a table in the database
  • 1x Template (to display the custom page)
  • 1x Plugin (adds a button to the navbar)
  • 3x PHP files (1 main file, 2 helper files)
What I've done till now:
  • Make product using: Plugin & Products > Manage Products > [Add/Import Product]
  • Put plugin inside product using: Plugin & Products > Plug-in Manager > [Edit] plugin > select Product in drop down box
  • Insert the database query for creating the table used by the product using: Plugin & Products > Manage Products > Edit product > Add New Install/Uninstall Code.
I can't figure out, where to:
  • Make the template a part of the product. I can see no setting which allow me to attach a template to any product.
  • Insert the 3 PHP files in the XML so that two go to the 'includes' directory and one goes into the root. Is this possible at all or will I have to add the PHP files and XML files to a zip and distribute that?
The standard response to a query such as mine has been to 'look at the XML of other products which are doing something similar'. Although I appreciate 'standing on the shoulders of giants' I would really like to know where those guys learnt this (I'm assuming this process is documented somewhere). I can't seem to find anything in the documentation. The current documentation is for vB3.x and the bit about adding a template to the product doesn't seem to be there at all.

Any help appreciated.

Vaupell 01-20-2010 11:28 AM

Well you need to setup a "developer" board, basicly a vbulletin running in debug mode.

and then you start by creating the product.
then each item you add, much have the new product selected.

and new templates should be created in "master" template, not default.

Then in the product menu when using export it will include
phrases, plugins, templates, etc etc.

Php files, you just add manually along with the product xml
manually uploaded dureing installation.

---

Creating a product for vb4 is still excaktly like vb3
and the vb3 documentation on vb.com is sufficient for creating, import/export
only the codeing part thats not the same.

http://www.vbulletin.com/docs/html/creating_a_product

---

So you now need to create a board running in debug,
i run one on my computer, locally using XAMPP server(google it),
installed vb on it, set it in config to run debug then you will notice
you have alot more options availible for exspecially deveping products,
adding options, etc..

remember new templates in masterstyle not default, if they are in default
they wont be included in the export.

saajjj 01-20-2010 11:43 AM

Hi Vaupell,
Thanks for your reply, enabling debug mode was the key.

Cheers,

Vaupell 01-20-2010 11:56 AM

Quote:

Originally Posted by saajjj (Post 1961108)
Hi Vaupell,
Thanks for your reply, enabling debug mode was the key.

Cheers,

btw, you dont want to enable debug mode on a live board.. :D

saajjj 01-20-2010 12:21 PM

Noted and thanks, I've been working on my laptop.

BBR-APBT 01-20-2010 07:40 PM

Well you can enable debug on a live site, But it is best to do it the following way.

Code:

if ($_SERVER['REMOTE_ADDR'] == 'xx.xxx.xx.xxx') {
    $config['Misc']['debug'] = true;
} else {
    $config['Misc']['debug'] = false;
}

Replace xx.xxx.xx.xxx with your ip address and the debug information will show only for you.

This will help to debug errors on your live site.

saajjj 01-20-2010 07:51 PM

Thanks BBR_APBT. That looks useful.

--------------- Added [DATE]1264065850[/DATE] at [TIME]1264065850[/TIME] ---------------

Thanks again for all your help, I was able to export/install the product successfully :)


All times are GMT. The time now is 03:54 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01244 seconds
  • Memory Usage 1,727KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete