vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   hook location for header footer (in thread) plugin? (https://vborg.vbsupport.ru/showthread.php?t=191324)

fabioski 09-19-2008 12:31 PM

hook location for header footer (in thread) plugin?
 
What hook location for plugin which has to working in HEADER AND FOOTER template in each thread?
Which hook location have I to choose?
I try with showthread_complete and showthread_getinfo but it doesn't work

The plug-in generate correctly the variable:
$testo_adv_header .= "$row_adv_header[adv_text]";
and I stamp it on site correctly:
echo "$testo_adv_header";

But in the template the variable does not appear!
<td>$testo_adv_header</td>
</tr>
</table>

And for footer template?

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

Is it not possible to make a plugin for Header template?

For example:
in my plugin i create this var:
$var1 = "<p>TEST PLUGIN</p>";

if I put in HEADER template this var:
$var1

I not read "TEST PLUGIN"

Which hook location Have I to use?

fabioski 06-30-2011 12:33 PM

Global_start doesn't work :(

kh99 06-30-2011 01:30 PM

The hook parse_templates is just before the header and footer templates are processed. But global_start is also before that so it should have worked. In your plugin, are you setting the variables in a function? If so, you may need a "global" statement to make it work.


All times are GMT. The time now is 01:02 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.01083 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