vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Uncached templates (https://vborg.vbsupport.ru/showthread.php?t=204667)

lasto 02-08-2009 06:14 PM

Uncached templates
 
im on vbull 3.8.1

and i have uncached templates on forumindex,does anyone know how i can cache them.
The templates which are showing up uncached are ones ive added myself so any help would be appreciated.

snakes1100 02-08-2009 07:14 PM

Read that article, roughly in the middle of the article.

https://vborg.vbsupport.ru/showthread.php?t=62164

lasto 02-08-2009 07:53 PM

65 pages is a lot to read m8

snakes1100 02-08-2009 08:11 PM

The first box gives a description of how to add templates to cache them, you can also use a plugin to cache the templates.

Lynne 02-08-2009 08:24 PM

hook location - cache_templates:

PHP Code:

if(THIS_SCRIPT == 'index'

$globaltemplates array_merge($globaltemplates, array( 
'xxx_yyyy'
'aaa_bbbb')); 


That's the basic format.

lasto 02-09-2009 03:21 PM

Lynne

im actually after caching templates that the link above points to as im using that to display external pages.
I know u done about hooks so do i just add that to the php file etc ??

Lynne 02-09-2009 04:07 PM

Just change:
PHP Code:

if(THIS_SCRIPT == 'index'

To:
PHP Code:

if(THIS_SCRIPT == 'yourpage'

or whatever you define THIS_SCRIPT to be in your script.

lasto 02-09-2009 04:09 PM

cheers will do

--------------- Added [DATE]1234209531[/DATE] at [TIME]1234209531[/TIME] ---------------

dont follow - do i add this into the actual PHP file ?

Dismounted 02-10-2009 05:36 AM

Plugin, no?
Quote:

Originally Posted by Lynne (Post 1738034)
hook location - cache_templates


Lynne 02-10-2009 03:05 PM

Yes, a create a plugin (Plugins & Products > Add New Plugin) using the "cache_templates" hook location.


All times are GMT. The time now is 05:25 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.01030 seconds
  • Memory Usage 1,737KB
  • 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
  • (3)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete