The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
Hi,
I am having an issue with a variable I want to call. PHP Code:
{vb:raw adss} in the navbar template. To be honest I did this just to test the variable, which I am sure should display?? I really wanted to call a custom code from the database using the forumid, but I guess I should get it outputting first Thank you for any advice Regards Mick |
#2
|
|||
|
|||
![]()
Your code looks right, but where did you put it? If it's in a plugin using a hook that is called after the navbar is constructed then that might be the problem.
|
#3
|
|||
|
|||
![]()
ahhh its in the showthread complete hook.
I wanted to pull data from the database (forum table) and output it in the navbar. I have unique data for each forum (forum.un_data), I wanted to display this on the navbar? Would that be possible? Thank you very much for your help. Mick |
#4
|
||||
|
||||
![]()
showthread_complete is too late
--------------- Added [DATE]1347742066[/DATE] at [TIME]1347742066[/TIME] --------------- I don't know if it's possible but you can try to use this on navbar {vb:raw global.forumid} (is it correct Kevin?) |
#5
|
|||
|
|||
![]()
Yeah, showthread_getinfo looks like a good one, it's after a lot of checks that might send the user somewhere else, but it's before the navbar is made. And you can use $threadinfo['forumid'] to know which forum you're in.
|
#6
|
|||
|
|||
![]()
KH99 you are the man!!
Thank you, I am going to try and pull the data from my custom forum info table. I was thinking something simple like PHP Code:
Thanks again Kevin you are a really big help. Mick |
#7
|
|||
|
|||
![]()
Oh, I see now, you already have the forum data available. Anyway, I'm not quite sure what you're asking but I think the answer is no, if you use the code you're showing there it should work without registering anything else.
|
#8
|
|||
|
|||
![]()
Hi Kevin,
I am trying to pull data onto the navbar from a custom field in the forum table. I have created a field called un_data I can enter different data into each forum.un_data. I will have a go, thanks for your help. Mick --------------- Added [DATE]1347749920[/DATE] at [TIME]1347749920[/TIME] --------------- Hi all, I have been working on outputting my code. PHP Code:
RESOURCE ID 52 Its not taking the data from adss in the database? thanks again for all the help. Mick --------------- Added [DATE]1347790989[/DATE] at [TIME]1347790989[/TIME] --------------- I got this working! It has been a long time since I messed with mysql, and you need to do something with the data lol (mysql_fetch_row - etc), it was stuck in a resource and I forgot to add the code to deal with the array. Thanks Mick |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|