PDA

View Full Version : Global variables on postbit_display_start


DJ Biscuit
09-09-2009, 12:53 AM
I am coding a plugin using the postbit_display_start hook, but gobal variables like $vbulletin->options[] doesn't work. Is there a way or getting the global variables to work on that hook, or am I doing something wrong?

Lynne
09-09-2009, 03:34 AM
Just make the variable global at the beginning of the plugin:

global $vbulletin;

DJ Biscuit
09-09-2009, 03:40 AM
Just make the variable global at the beginning of the plugin:

global $vbulletin;

Ah, it works. Thank you very much.