auto-include library scripts

This commit is contained in:
Shish Moom
2009-07-07 06:48:59 -07:00
parent 7f73a1f87e
commit f070bbe69e
6 changed files with 121 additions and 87 deletions

View File

@@ -80,6 +80,10 @@ class GenericPage {
case "page":
header("Cache-control: no-cache");
usort($this->blocks, "blockcmp");
$data_href = get_base_href();
foreach(glob("lib/*.js") as $js) {
$this->add_header("<script src='$data_href/$js' type='text/javascript'></script>");
}
$layout = new Layout();
$layout->display_page($page);
break;