apimag
01-06-2011, 04:49 AM
Trying to get file includes working, but without any luck. Have followed instructions here:
http://www.vbulletin.com/docs/html/templates_externalfiles
So, in short, have created a php file, "example_include.php" with the contents:
<?php
echo 'Include success!!';
?>
1. Dropped this into the forum root directory.
2. Created new plug-in:
ob_start();
include('example_include.php');
$includedphp = ob_get_contents();
ob_end_clean();
Selected "global_start"
Checked plug-in is active (and plugin feature generally is enabled).
3. Added {vb:raw includedphp} to the header under common templates.
4. Enabled debug to view that the file has in fact been included:
Included Files (15):
* ./index.php
* ./forum.php
* ./global.php
* ./includes/class_bootstrap.php
* ./includes/init.php
* ./includes/class_core.php
* ./includes/config.php
* ./includes/functions.php
* ./includes/class_hook.php
* ./example_include.php
* ./includes/functions_bigthree.php
* ./includes/functions_forumlist.php
* ./includes/functions_calendar.php
* ./includes/functions_notice.php
* ./includes/class_friendly_url.php
But I can't see the test message in the included php file anywhere (have searched source).
Any ideas out there please?
http://www.vbulletin.com/docs/html/templates_externalfiles
So, in short, have created a php file, "example_include.php" with the contents:
<?php
echo 'Include success!!';
?>
1. Dropped this into the forum root directory.
2. Created new plug-in:
ob_start();
include('example_include.php');
$includedphp = ob_get_contents();
ob_end_clean();
Selected "global_start"
Checked plug-in is active (and plugin feature generally is enabled).
3. Added {vb:raw includedphp} to the header under common templates.
4. Enabled debug to view that the file has in fact been included:
Included Files (15):
* ./index.php
* ./forum.php
* ./global.php
* ./includes/class_bootstrap.php
* ./includes/init.php
* ./includes/class_core.php
* ./includes/config.php
* ./includes/functions.php
* ./includes/class_hook.php
* ./example_include.php
* ./includes/functions_bigthree.php
* ./includes/functions_forumlist.php
* ./includes/functions_calendar.php
* ./includes/functions_notice.php
* ./includes/class_friendly_url.php
But I can't see the test message in the included php file anywhere (have searched source).
Any ideas out there please?