Forum Moderators: coopster
The problem (simplified) is using the phplib template library any var's a set in a function don't make it back to the calling function (anymore).
index.html
<html>
<body>
{value}
</body>
</html>
doesn't work:
include_once('template.inc');
$t = new Template(template_dir,"keep");
$t->set_file("mainpage","index.html");
footer($t);
$t->pparse("OUT", "mainpage");function footer($t){
$t->set_var("value","blah");
}
works:
include_once('template.inc');
$t = new Template(template_dir,"keep");
$t->set_file("mainpage","index.html");
$t->set_var("value","blah");
$t->pparse("OUT", "mainpage");