vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   why $vbulletin->options don't work in postbit_display_complete hook >>?????? (https://vborg.vbsupport.ru/showthread.php?t=218436)

Jason4Ever 07-12-2009 02:52 PM

why $vbulletin->options don't work in postbit_display_complete hook >>??????
 
hello,

plz i wrote plugin , but i stopped because i tried use option , but it didn't work in postbit_diplsay_hook , i tried $vbulletin->options[... , so what's the problem , why it's don't work with postbit_display_complete ?? and how to solve it ??

thanks,

Lynne 07-12-2009 03:04 PM

Let's see the plugin code. (Did you make $vbulletin global?)

Jason4Ever 07-12-2009 03:09 PM

hi,

no i didn't make $vbulletin global >? ,, how ?

this is cut of plugin code:
PHP Code:

if($vbulletin->options['smaw_onoff'] == 1
{
// code here .. 


all $vbulletin varibales don't work , like : $vbulletin->options['smaw_onoff'] although it work but in another hook like showthread

Lynne 07-12-2009 03:11 PM

To make $vbulletin global:
PHP Code:

global $vbulletin


Jason4Ever 07-12-2009 03:13 PM

where i put it ?

Lynne 07-12-2009 03:21 PM

Quote:

Originally Posted by Jason4Ever (Post 1847500)
where i put it ?

Somewhere before you want to use the variable $vbulletin. (Perhaps the first line of your plugin?)

Jason4Ever 07-12-2009 03:32 PM

very good , it's work now , thank u Lynne


All times are GMT. The time now is 01:10 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.00940 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
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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