Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Automatic Template Compiler Details »»
Automatic Template Compiler
Version: 1.00, by Adrian Schneider Adrian Schneider is offline
Developer Last Online: Nov 2022 Show Printable Version Email this Page

Category: Administrative and Maintenance Tools - Version: 3.7.0 Beta 4 Rating:
Released: 02-12-2008 Last Update: 02-12-2008 Installs: 82
Uses Plugins
Additional Files Is in Beta Stage  
No support by the author.

Development Tool: Automatic Template Compiler
Requirements: PHP 5, vBulletin 3.5+

Summary: Allows you to edit HTML files directly instead of using the AdminCP template editor. ATC will automatically update the database if any changes are detected. This is intended for a development environment only, and will only run while in debug mode.

Why: Template development is a huge PITA because of how templates are stored in the database - they are compiled. This means you cannot simply save a file, or update the database, because vBulletin needs to compile them first, and maybe even update the style cache. This saves TONS of time copy pasting and switching between your editor, your page, and the vBulletin template editor box.

How it works: ATC maintains a checksum (md5 hash) of each template body, and when it finds that one is out of sync with your working copy, it will save that template automatically in a very efficient manner. It updates both the template about to be displayed in memory and also the real copy in the database.

It also includes a very basic import utility so you can copy your existing templates into the filesystem for easy editing.

How to use it: Follow the install instructions, and then whenever you edit a file, the changes will transfer to vBulletin itself.

This was written in PHP 5 (OO) and I have no plans to make it work with PHP 4, but I may eventually build an interface to manage the settings, but for developers, configuring it should be no problem.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
2 благодарности(ей) от:
Hoffi, xorex

Comments
  #42  
Old 02-25-2008, 09:44 AM
Zachery's Avatar
Zachery Zachery is offline
 
Join Date: Jul 2002
Location: Ontario, Canada
Posts: 11,440
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cheesegrits View Post
I think you'd be amazed at how useful the ATC is, even if you don't do much template editing. You'll save the time it took you to install the ATC the first time you do need to edit a template. Template editing becomes just like PHP editing - make your changes to a simple HTML file using your IDE / code editor, and hit your page again.

I don't do a huge amount of template editing, but the ATC has already become one of those things I don't know how I lived without.

Even if you don't do template editing, just being able to dump all of vB's templates and include them in your IDE's "Search in Files" path is invaluable when trying to work out how vB does something. Like, what does $show['some_show_thingy'] do, how does it get set and where does it get used? One search in your IDE finds all occurrences in PHP and templates.

-- hugh
Meh, I know my way around the template system fairly well, its never bothered me editing it via admincp
Reply With Quote
  #43  
Old 02-25-2008, 05:54 PM
cheesegrits's Avatar
cheesegrits cheesegrits is offline
 
Join Date: May 2006
Posts: 500
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Zachery View Post
Meh, I know my way around the template system fairly well, its never bothered me editing it via admincp
I have no doubt you know the template system like the proverbial back of your hand. I just don't see how anyone could possibly want to use the ACP to edit templates, when they could be using an 'intelligent' HTML/CSS editor instead, and never have to touch the ACP.

IDE's or even basic code editors provide all kinds of nifty support for editing HTML/CSS, like attribute completion, syntax checking, pretty printing, complex search / replace, code snippets, macros, etc. If you have a good IDE (or just install WinMerge), it will also handle diff'ing and merging, making vB upgrading a snap - upgrade, use ATC to dump everything in Master and any customized styles in separate directories, do a "directory diff and merge" in your editor / WinMerge, done.

I just don't see why anyone who does anything like any serious template editing wouldn't want to take advantage of all that.

-- hugh
Reply With Quote
  #44  
Old 02-27-2008, 05:03 PM
vertigo jones vertigo jones is offline
 
Join Date: May 2007
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I love you.
Reply With Quote
  #45  
Old 03-06-2008, 09:04 PM
jGas jGas is offline
 
Join Date: May 2007
Posts: 172
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i was able to enable ( ) debug mode...but now what do i have to do to find the html file?

thanks!
Reply With Quote
  #46  
Old 03-07-2008, 12:31 AM
PyroNET PyroNET is offline
 
Join Date: Aug 2004
Posts: 72
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by vertigo jones View Post
I love you.
Couldn't have put it better myself.

Feature suggestions:

Make it able to update css too. One of the things I hate the most is the vBulletin CSS editor.

If I create an html file in the template folder that isn't currently a customized template have it detect such and edit the style to customize that template.
Reply With Quote
  #47  
Old 03-08-2008, 07:59 AM
jGas jGas is offline
 
Join Date: May 2007
Posts: 172
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

by the way, in the $config, what do you mean for product_id and version?

if i set it on:

HTML Code:
$config = array(
		'product' => 'vBulletin',
		'version' => '3.7.0 Beta 5'
	);
it doesn't create any html page on the template folder...
Reply With Quote
  #48  
Old 03-17-2008, 11:02 PM
aisais aisais is offline
 
Join Date: Jan 2005
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you for such smart idea. It saves a lot of time and efforts.
Tthanks again.
Reply With Quote
  #49  
Old 03-29-2008, 10:35 PM
akanevsky akanevsky is offline
 
Join Date: Apr 2005
Posts: 3,972
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Now, this is a very useful modification. Thank you for creating it. Maybe you should suggest jelsoft that they include this into their distribution. Not that I will installing any of the 3.7.0+ versions due to a lot of networking crap in there that I don't think can even be turned off, but still...
Reply With Quote
  #50  
Old 03-30-2008, 01:32 AM
brendanc brendanc is offline
 
Join Date: Mar 2005
Posts: 11
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does this work for 3.7.0 RC1?
Reply With Quote
  #51  
Old 03-30-2008, 01:34 AM
furst furst is offline
 
Join Date: Dec 2005
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Let me see if I understand this thing.

Does this mean that with this installed I can open my vBulletin in Dreamweaver, make whatever changes I want, and then it will be updated on my site just like that to reflect the changes I made? If so, that's awesome.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 05:18 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05396 seconds
  • Memory Usage 2,316KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_html
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (2)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete