vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3 Articles (https://vborg.vbsupport.ru/forumdisplay.php?f=187)
-   -   [How-To] Product Managament (vBulletin 3.5 RC 1 and up) (https://vborg.vbsupport.ru/showthread.php?t=92953)

akanevsky 08-01-2005 12:52 PM

Quote:

Reason = I don't like MS too much
Jeez...
Anyway, how about this: make two versions, a PDF and a CHM, to satisfy both those who like and those who dislike MS. Please thanks :)

Revan 08-01-2005 04:15 PM

Quote:

Originally Posted by KirbyDE
Reason = I don't like MS too much :)

That's really anal. That's like saying "I refuse to zip my hacks because I hate the WinZip program. I am blatantly ignoring the fact that WinRar/WinAce/[insert name of unpacking software for Mac/Linux/Unix] can unpack these files."
Making the How-to's HARDER to use is IMHO completely against the point of making them. I consider this a kick in the nuts to the community. This paragraph (and only this) will be retracted if someone can show me a way to copy/paste from Adobe Reader. I refuse to install any other piece of software to be able to copy/paste from a .pdf document, as I do not feel the need to clutter my computer with crap that will be used 1 or 2 times.
At any rate, see if you can stop me from making CHM files on my own computer (not to distribute).

Now to get back on the actual topic:
Ive learned the hard way that settings have to be volatile for them to be able to export properly, but won't this erase them on upgrade? The code in the xml_import_settings() makes me think that if you are trying to re-import settings that are marked as volatile, it will recreate these settings. This is not a desired effect, so I hope someone can prove me wrong :p

Andreas 08-01-2005 04:29 PM

Copying from PDF (if copying is permitted): Just use the Text Selection Tool, select the Text and click Edit/Copy.

Quote:

At any rate, see if you can stop me from making CHM files on my own computer (not to distribute).
Feel free to do that for your own. But as said, I do not allow distributing CHMs.

Volatile Settings will be deleted upon update. However, vBulletin only deletes its own (eg. produvt=vbulletin) Settings.

akanevsky 08-01-2005 04:55 PM

Quote:

That's really anal. That's like saying "I refuse to zip my hacks because I hate the WinZip program. I am blatantly ignoring the fact that WinRar/WinAce/[insert name of unpacking software for Mac/Linux/Unix] can unpack these files."
Making the How-to's HARDER to use is IMHO completely against the point of making them. I consider this a kick in the nuts to the community. This paragraph (and only this) will be retracted if someone can show me a way to copy/paste from Adobe Reader. I refuse to install any other piece of software to be able to copy/paste from a .pdf document, as I do not feel the need to clutter my computer with crap that will be used 1 or 2 times.
At any rate, see if you can stop me from making CHM files on my own computer (not to distribute).
I agree. "Reason = I dont like MS" is a very lame statememnt...

Quote:

Copying from PDF (if copying is permitted): Just use the Text Selection Tool, select the Text and click Edit/Copy.
That means I have to install Adobe PDF Editor, which is a bloated program that takes up a lot of space in my computer, and that is the reason why I do not have it installed. I'd rather just read the HowTo's from this site rather than from a PDF file...

Oh. And how can you restrict distrubting the CHM's? It's not like it is a copyrighted material. As long as your name is stated - there is no reason behind not distributing them, as well as there is no way you can "not allow it"...

Andreas 08-01-2005 05:00 PM

Quote:

Originally Posted by Dark Visor
That means I have to install Adobe PDF Editor, which is a bloated program that takes up a lot of space in my computer, and that is the reason why I do not have it installed.

No, just Arcobat Reader.

You don't like PDF, I don't like CHM and therefor I just don't support it.
So where is the Problem?

You can read the How-TOs here, build a CHM on your own or use the PDF (when there is one, which currently isn't the case anyway).

Quote:

And how can you restrict distrubting the CHM's? It's not like it is a copyrighted material. As long as your name is stated - there is no reason behind not distributing them...
It is copyrighted material. Everything one writes is automatically copyrighted if not stated otherwise.
(Although this might not always be the case considering general small talk and german copyright laws).

But if you feel happy, I can explicitly point this out too.

akanevsky 08-01-2005 05:07 PM

Quote:

No, just Arcobat Reader.
"just Acrobat Reader" is bloated enough itself... I prefer to use Easy PDF Reader, which consumes much less memory and therefore is easier to use. It, however, does not allow copying of the contents.

Quote:

You don't like PDF, I don't like CHM and therefor I just don't support it.
So where is the Problem?
The problem is that you are a minority on this case... The majority does prefer CHM. That's called being selfish. If you don't do it for other people, then why do it at all? I don't think anybody wants it in PDF format at all.

Quote:

It is copyrighted material. Everything one writes is automatically copyrighted if not stated otherwise.
(Although this might not always be the case considering general small talk and german copyright laws).

But if you feel happy, I can explicitly point this out too.
Ok. You are right - it is copyrighted. But as long as something is free and accessible by everyone, distribution in an easy-to-use-for-people format should be promoted. Because it will just make your name more known to other people. Besides, if I am stating your name in every article, I am not breaking the copyright. Prove me wrong.

Andreas 08-01-2005 05:12 PM

[ot]
Quote:

Originally Posted by Dark Visor
Besides, if I am stating your name in every article, I am not breaking the copyright. Prove me wrong.

Don't know for other contries, but german copyright laws do only permit personal usage and short ecerpts if you are publishing smth., you can't quote the whole document.

PDF is easy to use and available on multiple Platforms.

I am not going to support CHM.

EOD
[/ot]

Dream 08-03-2005 03:51 PM

are product phrases considered orphan phrases?

tehste 08-03-2005 04:05 PM

I like the product/hook thing I found it intuitive enough. Though it was always nice to read what you had to say about it, oh and this thread has provided some good amusement...

Princeton 08-28-2005 07:14 PM

Just starting to get into 3.5 - excellent tutorial :up:

thank you

EDIT: Is there any way to add a new hook without editing the xml file?

Andreas 08-28-2005 07:19 PM

You can add your own hooks_xxx.xml File.

Princeton 08-28-2005 07:27 PM

it doesn't show under HOOK LOCATION

thank you

Andreas 08-28-2005 08:02 PM

Due to the way it is currently implemented, your XML must define at least 2 Hooktypes:

Code:

<?xml version="1.0" encoding="ISO-8859-1"?>

<hooks>

        <hooktype type="custom">
                <hook>custom1</hook>
                <hook>custom2</hook>
                <hook>custom3</hook>
        </hooktype>

        <hooktype type="custom2">
                <hook>custom2_1</hook>
                <hook>custom2_2</hook>
                <hook>custom2_3</hook>
        </hooktype>
       
</hooks>

The Filename should match your Product ID.
Also, there should be hooktype_xyz Phrases in Phrasegroup Plugin System for all your Hooktypes.

Princeton 08-28-2005 08:45 PM

aha, thank you ... I got the phrasegroup and phrases all figured out also.

Paul M 08-28-2005 10:30 PM

Quote:

Originally Posted by KirbyDE
Reason = I don't like MS too much

:rolleyes:

Quote:

Originally Posted by KirbyDE
PDF is easy to use and available on multiple Platforms.

I am not going to support CHM.

What has you not supporting it got to do with denying anyone else the right to produce a CHM version, you wouldn't be supporting it if someone else did it :confused:

Boofo 08-29-2005 11:40 AM

How do you cache a template in a product file?

Andreas 08-29-2005 11:52 AM

@Paul M
If I did so, I would support CHM to be a succesful Format.
Thank you for your understanding that I am not going to do this.

@boofo
This Question doesn't make sense.
However, you can cache Templates in Hook cache_templates.

Boofo 08-29-2005 01:03 PM

Quote:

Originally Posted by KirbyDE
@boofo
This Question doesn't make sense.
However, you can cache Templates in Hook cache_templates.

What doesn't make sense? I wanted to cache a template in the product xml of my hack. And I was informed about the cache_templates hook right after I posted this request. I missed it before. ;)

Paul M 08-29-2005 02:31 PM

Quote:

Originally Posted by KirbyDE
@Paul M
If I did so, I would support CHM to be a succesful Format.
Thank you for your understanding that I am not going to do this.

No need to thank me. :) You don't actually have my understanding - I find your logic very odd. :ermm:

Andreas 08-29-2005 02:38 PM

@Boofo
It doesn't make sense because you can't "cache Templates in a Product XML"

Boofo 08-29-2005 04:26 PM

Quote:

Originally Posted by KirbyDE
@Boofo
It doesn't make sense because you can't "cache Templates in a Product XML"

You know what I mean, Kirby. The code and hook to cache it. ;)

Andreas 08-29-2005 04:33 PM

Well, that's possible :)

Boofo 08-29-2005 05:15 PM

And done! ;)

Evercraft 09-08-2005 03:15 PM

Great how to. answered some questions for me :)

One thing id like to know, or have more info on (cant find anything using search or browsing here or google), is about the option type (i.e textarea, yesno) and default values.

For example:

I would like to use a yesno box, but i cant seem to get the default to switch to yes. What default values do i use here?
Also id like to use a single line textfield rather than a text area. How do i do that?

I know maybe this should be answered in the questions forum, but I think this info would contribute to the howto as well :)

Andreas 09-08-2005 04:45 PM

Default for Yesno yes = 1

Albus 09-24-2005 05:46 PM

Kirby, can you clear up some things for me? I have set my test installation of 3.5RC3 to debug mode and I now see the "Add New Setting Group" and "Add New Setting" things, but I see nothing that corresponds to "Add New Phrase Group" or "Add New Template Group". I want to be able to totally segregate my product from the rest of vB. Does that make sense? Thanks in advance for your assistance and speedy reply.

Andreas 09-24-2005 05:51 PM

Adding Phrase Groups has to be done manually as there is no GUI for it.
1) Locate the maximum phrasetypeid in table phrasetype that is < 1000
2) Insert a new record into this table that has phrasetypeid=this value+1
3) Add a new colume phrasegroup_fieldname to table language
4) Rebuild languages
Then you can add Phrases to youre Phrasgegroup

Grouping Templates is done with a Plugin on Hook template_groups
PHP Code:

$only['prefix'] = 'Prefix'


Albus 09-24-2005 06:01 PM

Quote:

Originally Posted by KirbyDE
Adding Phrase Groups has to be done manually as there is no GUI for it.
1) Locate the maximum phrasetypeid in table phrasetype that is < 1000
2) Insert a new record into this table that has phrasetypeid=this value+1
3) Add a new colume phrasegroup_fieldname to table language
4) Rebuild languages
Then you can add Phrases to youre Phrasgegroup

Grouping Templates is done with a Plugin on Hook template_groups
PHP Code:

$only['prefix'] = 'Prefix'


If I do items 1-4, make the grouping plugin as directed and export the product, will the resulting xml file automatically set these up on a client? In other words, will the client installation show the new template group and phrasegroups as intended?

Andreas 09-24-2005 06:09 PM

Yes it will.

Albus 09-24-2005 06:18 PM

Quote:

Originally Posted by KirbyDE
Yes it will.

Thanks, I have on last question then regarding the grouping plugin. Given the following statement, the named templates are still not grouped. Am I missing something?

$only['prefix'] = 'test_product_';

test_product_header
test_product_footer

This should wrap up my queries for a bit. Thanks for your assistance Kirby.

Andreas 09-24-2005 06:25 PM

The Code should be
PHP Code:

$only['test_product'] = 'Test-Product'

Then it would show up as Test-Product Templates in Stlye Manager.

Marco van Herwaarden 09-24-2005 06:34 PM

Don't use the last underscore.

Albus 09-24-2005 06:53 PM

Quote:

Originally Posted by KirbyDE
The Code should be
PHP Code:

$only['test_product'] = 'Test-Product'

Then it would show up as Test-Product Templates in Stlye Manager.

Thanks!

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?

Marco van Herwaarden 09-24-2005 06:57 PM

Installation of new tables can be handled from the Product Manager, no need for installation scripts.

Andreas 09-24-2005 07:09 PM

@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.

Albus 09-24-2005 07:21 PM

Quote:

Originally Posted by KirbyDE
@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.

Hm, so technically I can create it all online and use the install/uninstall code boxes to make the call to add_phrase_type() and handle the table work? I see there's a version number field there too. This raises two questions.

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.

Andreas 09-24-2005 07:26 PM

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.

Albus 09-24-2005 07:29 PM

Quote:

Originally Posted by KirbyDE
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.

Ooh, that's nice. I think that wraps it up. One of us ought to compile all the instructions, comments and questions here so far into a downloadable document. Thanks!

JJR512 09-29-2005 02:55 AM

Where is writing the actual XML for a product covered?

Adrian Schneider 09-29-2005 03:02 AM

Quote:

Originally Posted by JJR512
Where is writing the actual XML for a product covered?

Take a look at some other products... most of the time you can generate them (export product), but sometimes you may have to go and edit the XML yourself.


All times are GMT. The time now is 12:24 AM.

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.02800 seconds
  • Memory Usage 1,853KB
  • 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
  • (4)bbcode_php_printable
  • (22)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete