The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
vbphrase for header plugin...or not
Hi all, i've tried to research and not ask too many stupid questions, but i've really struggled to get to the point of developing a hack/plugin, although i've managed a basic plugin, now i'm lost.
I've got a plugin which hooks into global_start and outputs to a var ($x), $x is called in the header section of the board. It contains a login form/information, however the $vbphrase for the message totals ect are not displaying, so i assume these are populated later than global_start. Is there a more appropriate hook for me to use, or do you have any other advice to get arround the issue. Really appreciate any help. J. |
#2
|
||||
|
||||
Can you post up the code you are using?
|
#3
|
|||
|
|||
ok for the purpose of the problem..
my plugin contains this type of code.. Code:
$info = $vbphrase[unread_x_nav_compiled]; Code:
$info Many Thanks J. |
#4
|
||||
|
||||
Which hook location are you using?
|
#5
|
|||
|
|||
global_start
|
#6
|
||||
|
||||
global_start is called before the header is built, so the whatever you are trying to assign to $info must not exist. Please post the actual code, not similar examples.
|
#7
|
|||
|
|||
No, that is an exact example, i want to assign $vbphrase[unread_x_nav_compiled] at global_start and it doesn't work I've got load of irrelevant code which works fine, Its the $vbphrase which doesn't work, hence the question.
|
#8
|
|||
|
|||
ok i've changed my plugin, so it excludes everything else and i can post the exact code. As you will appreciate its the same, but i realize its easier to help if you see the full code. It hooks at global_start and just contains:
Code:
$TestVar = "Test Output = "; $TestVar .= $vbphrase[unread_x_nav_compiled]; Code:
$TestVar If anyone can help, it would be greatly appreciated. J. |
#9
|
|||
|
|||
Try using the construct_phrase function...
$TestVar = construct_phrase('unread_x_nav_compiled'); |
#10
|
|||
|
|||
Its probably because you need to set a value for X thats why it won't work. Try setting it to zero or something and seeing what happens. Something like this:
PHP Code:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|