The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Hack designing help for a newbie
Hi,
I am new to VB but experienced in php. What I intend to do is to set up a hack allowing to inforce a template for posting. The solution I came up with would be something like: -> Add a column to the thread table to store wether or not it is a templated thread, and if it is, then the ind of templating: TEMPLATE_OFF / TEMPLATE_ALL_POSTS / TEMPLATE_FIRST_POST / TEMPLATE_REPLIES / TEMPLATE_MOD_POSTS / TEMPLATE_UNNREG_USERS_POST.... -> Add a column to the thread table to store the template id in case anything but TEMPLATE_OFF is used. -> Create a new table to store the template under XML format. The following example show how I can imagine it: <TEMPLATE type=TEMPLATE_FIRST_POST> <TEXT name="Character Name" maxlength="25" mandatory="true" validationtype="ereg" validation2="[a-zA-Z]{5,25}"> <TEXT name="Character Age" mandatory="true" validationtype="integer"> <MULTILINE name="Character description" maxlength="125" mandatory="false"> </TEMPLATE> -> Before displaying the form to post/reply/edit a post, template is browsed and depending of the template, the appropriate template is built. once submitted, this form would be compute into xml and inserted as message body. Display form would look like something like: Character name: [/i]<input type=txt>[/i] Character age: [/i]<input type=txt>[/i] Character description: [/i]<textarea>[/i] -> before displaying post in a thread, the xml content is compute once again to create formatted text without XML. I don't have any expertise of VB, so I wouldn't mind comments/suggestions or even help if this kind of a hack interest you. Thanks, Matt. |
#2
|
||||
|
||||
<a href="https://vborg.vbsupport.ru/showthread.php?t=61780" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=61780</a>
Don't double-post please. |
#3
|
|||
|
|||
Sorry...
I though I misplaced the first one but was unable to delete it... |
#4
|
||||
|
||||
I'll delete it for you.
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|