The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Adding PHP include file to header
Hi there
Can you please point me in the right direction on how to add a PHP include file in our forum header? I want to add <?php include('{Path to file}');?> to our header. I have a PHP file which produces some test output which I want to display? Any help will be much appreciated. |
#2
|
||||
|
||||
You'll have to utilize the plugin system and hook at global_start.
http://www.vbulletin.com/docs/html/t..._externalfiles |
#3
|
|||
|
|||
Solved it thanks...
|
#4
|
|||
|
|||
How did you solve it?
I'm having a problem with one of my plug-ins that isn't working properly. Plugin Code Code:
ob_start(); require_once('sigStrip.php'); $sigStripPHP = ob_get_contents(); ob_end_clean(); $sigStripPHP A vB guy told me to use $globals['sigStripPHP'] to call it, but I get errors when I go to do that and no posts display. The sigStrip.php for now just contains the following: Code:
<?php echo "Test"; ?> |
#5
|
||||
|
||||
No, you would call it with $sigStripPHP.
|
#6
|
|||
|
|||
I've tried that as well. It almost seems it's not even executing / including the phpfile when I do that, but when I check Debug mode, it does include it.
It just isn't displaying any of the output, in this case, the word "Test". |
#7
|
|||
|
|||
Which hook location are you using for the plugin?
|
#8
|
|||
|
|||
global_start
|
#9
|
||||
|
||||
Just to cover all the bases, you are using $sigStripPHP in a template, right? If so, which?
|
#10
|
|||
|
|||
Yes. I have it entered into the postbit_legacy under the signature.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|