Location: PHPKode > projects > Content*Builder > libraries/CB_runtime.inc.php
<?php

	global $tpl, $rel;	
	$rel = "../";
	include($rel."prepend.php");	
	
	if(!isset($openfolder)) { $openfolder = "fdaf"; };
	
	######## Don't modify from here ##########
	function loadModule($name, $position, $directory, $startFile, $main = false) {
		global $BTPL_module;
		if($main) {
			$mainSet = true;
		} else {
			$mainSet = false;
		}
		$BTPL_module->setModule(
			array ( "name"      => $name,
					"position"  => $position,
					"directory" => $directory,
					"file"      => $startFile,
					"main"      => $mainSet
			)
		);
	}
	
	function displayModule($name) {
		global $BTPL_module;
		$BTPL_module->displayModule($name);
	}
	
	$preview = FALSE;
	
	
	### Starting the template output ###
	$t_basedir = "../templates/default/";
	$t_images  = "../templates/default/images/";
	
	$tpl = new patTemplate;
	$tpl->setBaseDir($t_basedir);
	
	$tpl->readTemplatesFromFile("contentbuilder.template");
	$tpl->readTemplatesFromFile("forum.template");
	$tpl->addGlobalVar("IMAGEDIR",	$t_images);
	$tpl->addGlobalVar("TEMPLATE_DIR", $t_basedir);
	$tpl->addGlobalVar("PHP_SELF",	$PHP_SELF);
	$tpl->addGlobalVar("CBPATH",	$path["cb"]);
	$tpl->addGlobalVar("RELPATH",	$rel);
		
	include($rel."modules.php");
	
	$BTPL_module->displayParsedModules();
	
	$tpl->addVar("area:left:modules", "MODULE_CONTENT", $lModuleContent);
	
	global $patTpl;
	$patTpl = $tpl;
	
	unset($tpl);
	unset($path);

?>
Return current item: Content*Builder