]> git.mjollnir.org Git - s9y.git/commitdiff
Version 1.2.1 ()
authorgarvinhicking <garvinhicking>
Wed, 29 Aug 2007 19:54:36 +0000 (19:54 +0000)
committergarvinhicking <garvinhicking>
Wed, 29 Aug 2007 19:54:36 +0000 (19:54 +0000)
------------------------------------------------------------------------

    * Bulletproof template can now include custom user stylesheets
      (*_style.css) in the dropdown of a colorset. (garvinhicking)

docs/NEWS
templates/bulletproof/config.inc.php

index e381bb22007deb375a6f50430e8181aec2795039..d7de3de5eaa15b2f4fbb0c5841c2f471c414e615 100644 (file)
--- a/docs/NEWS
+++ b/docs/NEWS
@@ -35,6 +35,12 @@ Version 1.3 ()
     * Full pingback support, fallback trackback method for WordPress
       blogs. (brockhaus)
 
+Version 1.2.1 ()
+------------------------------------------------------------------------
+
+    * Bulletproof template can now include custom user stylesheets
+      (*_style.css) in the dropdown of a colorset. (garvinhicking)
+      
 Version 1.2 (August 26th, 2007)
 ------------------------------------------------------------------------
 
index ce396b24b2f7d8bed2a36d8db4f9c918f76de722..706b2b9f637eafe88ca741ed3063f304aabea517 100644 (file)
@@ -8,21 +8,35 @@ $probelang = dirname(__FILE__) . '/' . $serendipity['charset'] . 'lang_' . $sere
 if (file_exists($probelang)) {\r
     include $probelang;\r
 }\r
-    \r
+\r
 include dirname(__FILE__) . '/lang_en.inc.php';\r
 \r
 $serendipity['smarty']->assign(array('currpage'=> "http://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']));\r
 \r
+$colorsets = array(\r
+    'purple' => BP_COLORSET_OPT1,\r
+    'blue'   => BP_COLORSET_OPT2,\r
+    'green'  => BP_COLORSET_OPT3,\r
+    'blank'  => BP_COLORSET_DEF\r
+);\r
+\r
+if ($serendipity['GET']['adminModule'] == 'templates') {\r
+    $css_files = glob(dirname(__FILE__) . '/*_style.css');\r
+    foreach($css_files AS $css_file) {\r
+        $css_file = str_replace('_style.css', '', basename($css_file));\r
+        if (!isset($colorsets[$css_file])) {\r
+            $colorsets[$css_file] = $css_file;\r
+        }\r
+    }\r
+}\r
+\r
 $template_config = array(\r
     array(\r
         'var'           => 'colorset',\r
         'name'          => THEME_COLORSET,\r
         'type'          => 'select',\r
         'default'       => 'purple',\r
-        'select_values' => array('purple' => BP_COLORSET_OPT1,\r
-                                 'blue' => BP_COLORSET_OPT2,\r
-                                 'green' => BP_COLORSET_OPT3,\r
-                                 'blank' => BP_COLORSET_DEF)\r
+        'select_values' => $colorsets\r
     ),\r
     array(\r
         'var'           => 'layouttype',\r