JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
set $running_locally (wfpl doesn't anymore)
[wfpl-cms.git] / code / cms.php
index d6229b4..4f42655 100644 (file)
@@ -1,6 +1,9 @@
 <?php
 
 function cms_display($basename, &$tem) {
+       if(preg_match('/([.]l(ocal)?$)|^[0-9.]*$/', $_SERVER['HTTP_HOST'])) {
+               $GLOBALS['wfpl_main_template']->set('$running_locally');
+       }
        $tem->set('$host', this_host());
        $nav_items = db_get_assocs('cms_pages', "coalesce(nullif(nav_title,''), title) as title,filename", 'where navbar!=0 order by navbar');
        if($nav_items) {