Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/266.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php IPB-在自定义页面中包含模板_Php_Templates_Template Engine_Ipb - Fatal编程技术网

Php IPB-在自定义页面中包含模板

Php IPB-在自定义页面中包含模板,php,templates,template-engine,ipb,Php,Templates,Template Engine,Ipb,我愿意使用与我的IP.Board使用相同模板的自定义页面,但我想避免使用任何插件来实现相同的功能。 目前我有: <?PHP //define( 'IPS_ENFORCE_ACCESS', TRUE ); // Important so it does not redirect to forums define( 'IPB_THIS_SCRIPT', 'public' ); require_once( 'initdata.php' ); require_once( IPS_ROOT_PATH

我愿意使用与我的IP.Board使用相同模板的自定义页面,但我想避免使用任何插件来实现相同的功能。
目前我有:

<?PHP
//define( 'IPS_ENFORCE_ACCESS', TRUE ); // Important so it does not redirect to forums
define( 'IPB_THIS_SCRIPT', 'public' );
require_once( 'initdata.php' );
require_once( IPS_ROOT_PATH . 'sources/base/ipsRegistry.php' );
require_once( IPS_ROOT_PATH . 'sources/base/ipsController.php' );

$ipbRegistry    = ipsRegistry::instance();
$ipbRegistry->init();

$output = $ipbRegistry->getClass('output');
$output->addContent("<h1>Well, this is a test! </h1>");
$output->setTitle("Test page");
$output->sendOutput();

<?PHP
require "global.php";

// Some simple calls to initialize and set variables used below
// -------------------------------------------------------------
// Output HTML + required code from MyBB previously defined
echo "<!doctype html>
{$mybb_header}
<body>
<p>Some content</p>
{$mybb_footer}
</body>
</html>";