View Full Version : Organize your templates!
magnus
04-05-2004, 10:00 PM
If you're like me, you like to try to keep your board as organized as possible. Which, is why the following little tip comes in handy for hacks that add a dozen or so custom templates. (ie. vBindex, v3arcade, etc..)
In includes/adminfunctions_template.php:
Find:
'subscription' => $vbphrase['group_paid_subscriptions'],
Add BELOW:
'XXprefixXX' => 'XXtitleXX',
Change "XXprefixXX" to whatever the template prefixes are, for example, the Arcade templates all begin with "arcade", so, you would put "arcade" as the prefix.
Change "XXtitleXX" to what you want the category to be called, don't add "Templates" to the name, because vB will do that for you. For example, if you put "arcade" as the title, it will read "Arcade Templates" in the Edit Templates section.
Get it? Good. :)
magnus
04-06-2004, 01:56 AM
Err.. this should be in Modification Hints and Tips (https://vborg.vbsupport.ru/forumdisplay.php?f=20), could a moderator please move it for me? :)
Link14716
04-06-2004, 03:21 AM
Err.. this should be in Modification Hints and Tips (https://vborg.vbsupport.ru/forumdisplay.php?f=20), could a moderator please move it for me? :)
Although technically it is a mini-mod as well, heh. ;)
Red Blaze
04-06-2004, 04:15 AM
Ahh, now it looks less painful to see all those templates. Thanks! ^_^
Fi_InCogNiTo
04-06-2004, 04:25 AM
Wow, beautiful tip there!
As my wife says, so small, but damn it's so usefull!!!
/me clicks install
Red Blaze
04-06-2004, 04:55 AM
so small, but damn it's so usefull
that.... that sounds wrong man. o.O; I blame my perverted mind, yet I know what you mean...... but still *shivers*
SVTBlackLight01
04-06-2004, 06:11 AM
That's a great tip. I have definately found it useful and think this step should be added to any hack with multiple new templates.
BarBeQue
04-06-2004, 08:32 AM
Fine mod!
Been looking for a way to accomplish this, now i found it :D
* BarBeQue will click install tonite, when he's home and actually installed it.....
PixelFx
04-06-2004, 09:59 AM
very nice, to do the same in vb2 was painful, hehe this is so easy !!
BarBeQue
04-06-2004, 06:50 PM
* BarBeQue clicked install
:D worked like a charm!
Mijae
04-06-2004, 07:27 PM
* BarBeQue clicked install
:D worked like a charm!
I requested this but no one answered :P This is great!
paddysplace
04-07-2004, 02:15 AM
I was just asking for this a few hours ago in #vborg. Thank you SO much! I will definitely put this in my hacks (crediting you of COURSE!)
Regards,
Patrick
FleaBag
04-07-2004, 04:41 PM
Small - but very handy. Cheers. :D
Boofo
04-07-2004, 06:02 PM
If adding this code so templates can be grouped, won't this cause the templates to be erased on a vb upgrade?
magnus
04-07-2004, 08:02 PM
If adding this code so templates can be grouped, won't this cause the templates to be erased on a vb upgrade?
No, I don't think so. They are still classified as "custom templates" by vB. If you "revert" them, they will still be deleted. This doesn't change any of their SQL flags, as that's where vB determines what gets replaced during an upgrade.
gmarik
04-08-2004, 05:39 PM
great idea, really coold
Synicide
05-12-2004, 09:22 PM
Well, I hope they don't get deleted, because I'm jumping into this hack anyway. :D
* Synicide jumps on the install button.
attroll
05-23-2004, 03:02 PM
Let me see if I get this right. I installed this mod and this is what I put in the "'articles' => 'articles'," in my adminfunctions_template.php. Everything seemed to work fine.
But my question is:
When I create a new template now how do I get it listed under ARTICLES?
Do I have to name the new template articles_test?
Onkel_Tom
06-03-2004, 10:11 AM
works fine, thanks !
click install
Change "XXtitleXX" to what you want the category to be called, don't add "Templates" to the name, because vB will do that for you. For example, if you put "arcade" as the title, it will read "Arcade Templates" in the Edit Templates section.
Get it? Good. :)
well, this is good, but ... I'd like to group the "custom templates" or "custom groups" in one place, so I dont need to go though the whole list of templates to find the custom ones. Tor example, I am grouping some xzy_ templates, as xzy, and prefer them to be displayed on top, or still in Cumstom Templates group.
dunno if it's posible.
this is very useful! :D
i'm happy today
ImportPassion
06-25-2004, 12:56 AM
well, this is good, but ... I'd like to group the "custom templates" or "custom groups" in one place, so I dont need to go though the whole list of templates to find the custom ones. Tor example, I am grouping some xzy_ templates, as xzy, and prefer them to be displayed on top, or still in Cumstom Templates group.
dunno if it's posible.
ya be cool to have these now custom groups at the top since they are still custom
Erwin
06-25-2004, 01:02 AM
Cool tip. :) I like my custom templates separated, so I won't actually install this, but will still say that this is a simple yet useful mod.
Mr. Brian
06-26-2004, 01:09 AM
Nice one! Thanks for sharing. :)
GamerzWorld
06-26-2004, 08:16 AM
Great hack :)
Princeton
06-29-2004, 11:24 PM
nice tip:up:
y2krazy
08-29-2004, 11:57 PM
/me clicks install!
Revan
08-30-2004, 12:58 PM
* Revan clicks install
Great hack, it always pissed me off that the Arcade templates didnt get their own group ;)
Actually I think I will use this to group the RPG Templates in future versions :)
sv1cec
11-19-2004, 07:28 AM
Just make sure that the phrase you enter for the prefix is in lowercase letters. If it is in caps (even if they appear to be caps in the template name), it doesn't work for some reason.
I had some templates which started with "ActivationEmail" and I had to enter "activationemail" for it to work.
Rgds
---------------
John
PennylessZ28
11-25-2004, 04:56 PM
Awesome Information, it helps to know. Thanks.
With over 100 custom templates on my board, I've wanted to know how to do something like this for a while, it really makes things easier. THANKS :D
* N8 clicks install
exTracT
01-13-2005, 04:03 PM
nice
ChrisBaktis
01-20-2005, 12:53 AM
I cant get this to work.
I added 'chris' => 'chris',
and then added a template called 'chrisindex' and this doesnt make any new catagory at all.
moethelawn
01-20-2005, 12:59 AM
I cant get this to work.
I added 'chris' => 'chris',
and then added a template called 'chrisindex' and this doesnt make any new catagory at all.
I think you need a _ between chris and index. (like chris_index). But if you want chrisindex... you'll need to have it as: 'chrisindex' => 'chrisindex'
or even
'chrisindex' => 'chris',
Cause vB will look at the name before the _
Hope that helps :)
ChrisBaktis
01-20-2005, 01:08 AM
For some reason I am just stumped.
New Code
'chris_trade' => 'trade_pages_chris',
My attempt here is to have a bunch of templates named 'chris_trade_XYZ' under the catagory Trade Pages Chris Templates
According to the directions my code should be right with a template called 'chris_trade_index' falling under trade pages chris templates'
Maybe Im tired but im lost for some reason on this.
ChrisBaktis
01-20-2005, 01:38 AM
got it - thanks
S@NL - BlackBik
03-03-2005, 09:02 PM
Thanks a lot, I was looking for a way to do this :)
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.