Announcement

Collapse
No announcement yet.

How do I use variables in the header template?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • WiZDoM
    replied
    That just helped me a LOT! Thanks!

    Leave a comment:


  • daemon
    replied
    The header template isn't special, it's just evaluated/generated in global.php, not index.php. So if you want a variable to be evaluated in the header template, you have to put it in global.php. If you have any more questions about modifying files, however, you should go to vBulletin.org where discussions regarding code changes can be done.

    Leave a comment:


  • WiZDoM
    started a topic How do I use variables in the header template?

    How do I use variables in the header template?

    Hi,

    I am currently still building my forums, and I have a funny feature, that I want to show up in my header template.

    So in index.php, let's say that I have a variable called $example, and I want this to show up in the header template.

    Problem is that it don't show up. I have also tried using this variable in my FORUMHOME template, and it works great there.. still in the wrong place though..

    I tried creating another template that contains my variable, and then calling it from index.php and linking it again in header.php, but it didn't work either.

    Is the header template a special template?
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Working...
X