![]() |
Forum Info
I use $foruminfo[title] to get the title of each forum on each page, and then use that information for a custom ad solution. After testing it, though, I realized that when you drill-down into the thread level, it picks up the name of the thread; I'd rather it just keep the name of the overall forum.
For instance, if you have "National Football League" as a forum, and then several threads within that forum: "Chicago Bears", "NY Jets", etc. - I need a way to access the forum name "National Football League" on every page, even the lower-level thread pages. Does anyone know how to do this? |
Use this:
Code:
$vbulletin->forumcache[$thread['forumid']]['title']; |
Use {$vbulletin->forumcache[$thread[forumid]][title]} in templates.
|
Quote:
|
It is available. :) Try putting {$vbulletin->userinfo[username]} in a template.
|
Quote:
|
I'm able to get {$vbulletin->userinfo[username]} to return the username value, but when I try and use {$vbulletin->forumcache[$thread[forumid]][title]}, it returns nothing - it doesn't error, it just returns a null or blank value.
|
I seem to recall that templates have some problem with multiple arrays - i.e. $var[x] will be okay, but $var[x][y] seems to fail, even though it exists. Although I thought that the use of braces fixed the problem ....
|
Quote:
|
it depends on the scope within which the template was called.
$vbulletin will only be available within a function if you global $vbulletin; first. |
All times are GMT. The time now is 02:13 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|