vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   why precache templates, i'm not finding it in the code.... (https://vborg.vbsupport.ru/showthread.php?t=91617)

Dionysis 07-04-2005 05:53 PM

why precache templates, i'm not finding it in the code....
 
In all the pages there are arrays like $phrasegroups, $specialtemplates, $actiontemplates etc.

what is the purpose of these? I can't find where they are called anywhere else in the code.

the templates are just pulled from

PHP Code:

eval('print_output("' fetch_template('TEMPLATE') . '");'); 

anyway

Zachery 07-04-2005 06:00 PM

If you don't precache a template a query is issued to get the template, and or every template on the page.

Dionysis 07-04-2005 06:32 PM

right, that is what i'm looking for in the code. But doing a bunch of crtl+F for "$actiontemplates" and associated arrays brings up nothing so i can't find where it's being used.

Adrian Schneider 07-04-2005 06:38 PM

I think you're looking for $globaltemplates - actiontemplates are from datastore.

Andreas 07-04-2005 06:46 PM

No ;)
$actiontemplates is an array defining Templates needed for special actions.
So these will only be loaded when the Scripts executes the assigned action - global.php merges this array with $globaltemplates for the action currently beign called.

What you mean is $specialtemplates.

Dionysis 07-04-2005 07:02 PM

Quote:

So these will only be loaded when the Scripts executes the assigned action
yea, WHERE? where in the code ^_^. I want to look it over myself :squareeyed:

Andreas 07-04-2005 07:04 PM

global.php, but where exactly depends on the Version.
For vBulletin 3.0.7 its around line 293.

For vBulletin 3.5 Beta 3 its around line 262.

Dionysis 07-04-2005 07:15 PM

Ah! thank you much.


All times are GMT. The time now is 10:26 AM.

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.01051 seconds
  • Memory Usage 1,721KB
  • 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)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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