vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Custom Template Adder Script (https://vborg.vbsupport.ru/showthread.php?t=63112)

Dream 03-28-2004 10:00 PM

Custom Template Adder Script
 
This is really something to help modders to add custom templates more easily in their releases.

Description: This script lets you specify which styles you want to add custom templates to. It also shows if a style has custom templates with the same names, and lets you overwrite them. You can also see the template codes you are about to add by clicking on the names.

Instructions: Edit in customtemplates.php:
$mod_name - your mod name
$script_file - the file name, if you modify it, without ".php"
$template array - each custom template you wanna add, beginning at index 1, as an associative array with 'title' and 'template' as key/values.

Example:
$template[1]['title'] = 'custom_template_example';
$template[1]['template'] = 'Dream\'s custom template "example".';

Demo: upload customtemplates.php to your admin cp folder, and call it from a browser.


I hope you find some use for this, modify at your heart's content. Included is a script to add v3 Arcade's custom templates, the reason why I made this in the first place.

[edit]typos[/edit]

AN-net 03-29-2004 04:14 AM

cool hack:)

BarBeQue 03-29-2004 09:30 AM

nice idea!

i just hope there will be some user input on overwriting custom templates, cause i often mod those myself a bit. Would hate it if a newer version would overwrite my custom templates


All times are GMT. The time now is 01:22 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.04884 seconds
  • Memory Usage 1,709KB
  • 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)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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