X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=run.php;h=3d0b1d4d5e2bbe66a7d9b7dc1a6d7bef69e349c9;hb=27f182546d729a9d297091799fcf1a1922da0c5e;hp=3a3d85a2d285e718437186d88f60c0f978bfcfd6;hpb=97722b7dc03c635483cf18bdeec9a8f18c1d7260;p=wfpl.git
diff --git a/run.php b/run.php
index 3a3d85a..3d0b1d4 100644
--- a/run.php
+++ b/run.php
@@ -1,24 +1,9 @@
404404 File Not Found
';
- }
+ echo '404404 File Not Found
';
+ }
+ }
+
+ $data = &$GLOBALS['wfpl_tem_data'];
+ $data['basename'] = $basename;
+ if(function_exists('display_messages')) {
+ display_messages();
+ }
+ if($cms_content) foreach($cms_content as $name => $value) {
+ $data[$name] .= $value;
+ }
+ if(file_exists("$basename.css")) {
+ $data['css_link'] = "$basename.css";
+ }
+
+ if(file_exists("template.html")) {
+ $template = parse_template_file("template.html");
+ if($html_exists) {
+ $subs = parse_template_file($html_file);
+ $template = merge_templates($template, $subs);
}
+ } elseif($html_exists) {
+ $template = parse_template_file("$html_file");
}
+ if($template) print fill_template($template, $data);
}
run_php();