The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to modify original vB templates via product?
Hi,
I've got a 'product' that modified original vB templates. At the moment it just appears to overwrite them and when I uninstall my product, the original templates are gone too. So now, forumhome is missing for example. This doesn't appear to be the right way. What is the right way? Greetings |
#2
|
|||
|
|||
This is totally wrong forum.
|
#3
|
|||
|
|||
Yes, hehe, sorry, I noticed when it asked me all the extra details. Could a mod move it or do I have to repost it?
|
#4
|
||||
|
||||
Hey Olaf,
Download a couple of my hacks and have a quick look at the some of the plugins. You should get the idea pretty quickly on how to do it. But if you use vBulletin's template hooks, which are in most templates now adays, it would look something like this: Code:
$template_hook['navbar_search_menu'] .= '<tr><td class="vbmenu_option"><a href="tags.php'.$session['sessionurl_q'].'" rel="nofollow">'.$vbphrase['bookmarksnavlink'].'</a></td></tr>'; Code:
$vbulletin->templatecache['FORUMDISPLAY'] = str_replace($vbulletin->options['sfutbf_ati_text'],$vbulletin->options['sfutbf_ati_text'].fetch_template('UnansweredThreadsByForum'),$vbulletin->templatecache['FORUMDISPLAY']); Mosh |
#5
|
|||
|
|||
If you have questions/problems with a modification or style, then please post in the thread (or support forum/board) about that modification/style. Best chance to receive a reply from either the author or another member using the same modification/style.
|
#6
|
|||
|
|||
Quote:
Template hooks sound nice. When did they get introduced? |
#7
|
|||
|
|||
Template hooks where introduced in 3.6.
You should never modify a default vBulletin template and ship that modified template with a product. It will overwrite the template in teh master style and will not revert anymore to default vB when uninstalled. |
#8
|
|||
|
|||
Quote:
However, the methods posted by Mosh aren't very flexible. |
#9
|
|||
|
|||
Quote:
There's no hook, so only method 1 could be used. However, method 1 isn't easy either in this case. Flexibility is also low. |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|