[pmwiki-users] PHP includes

Anno anno at shroomery.org
Mon Mar 27 08:42:38 CST 2006


> Can I make this statement work: 
> <?php include ("includes/navMenu.inc"); > 

Not directly, since the template file is not parsed as php.

You need to define this function in config.php:

function IncludeSidebar
{
ob_start();
include_once('includes/navMenu.inc');
return ob_get_clean();
}

And in the template where you want the menu, you write:

<!--function:IncludeSidebar-->





More information about the pmwiki-users mailing list