aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/SwiftThemeCreator/theme_creator.php
diff options
context:
space:
mode:
authorvdigital <vdigital@piwigo.org>2008-07-23 06:21:59 +0000
committervdigital <vdigital@piwigo.org>2008-07-23 06:21:59 +0000
commit49f337a9d8964f8ecd3c8c5eb75601ba9635df13 (patch)
tree30dc908c5c523932b1b695e349baaa17165a02bb /plugins/SwiftThemeCreator/theme_creator.php
parentcde423fc86a8aaa6054179ca17e534f53df1a422 (diff)
Swift Theme Creator (minor changes): non functional version yet (4).
Bug 836: "Extend for templates" minor change. git-svn-id: http://piwigo.org/svn/trunk@2453 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'plugins/SwiftThemeCreator/theme_creator.php')
-rw-r--r--plugins/SwiftThemeCreator/theme_creator.php18
1 files changed, 13 insertions, 5 deletions
diff --git a/plugins/SwiftThemeCreator/theme_creator.php b/plugins/SwiftThemeCreator/theme_creator.php
index 860b45097..1c9f0d9df 100644
--- a/plugins/SwiftThemeCreator/theme_creator.php
+++ b/plugins/SwiftThemeCreator/theme_creator.php
@@ -175,10 +175,6 @@ if (isset($_POST['submit']) and (!is_adviser()))
if ((( (($r1+1)/256)*(($g1+1)/256)*(($b1+1)/256) ) * 1000 ) < 125 )
$main['color7'] = lighten( $r1, $g1, $b1, 10);
else $main['color7'] = darken( $r1, $g1, $b1, 10);
-
- /* en gros reste à faire:
- * creation des différents fichiers
- */
// Go ahead
if (count($errors) == 0) {
@@ -189,6 +185,7 @@ if (isset($_POST['submit']) and (!is_adviser()))
l10n('Theme directory creation failure: it can\'t be created (for now en attendant la suite 8-) ).'));
}
+ $main['ldelim'] = '{ldelim}';
/*
* Build themeconf.inc.php
**/
@@ -197,6 +194,13 @@ if (isset($_POST['submit']) and (!is_adviser()))
dirname(__FILE__) . '/themeconf.inc.tpl'));
$plugin_tpl->assign('main',$main);
$main['themeconf_inc_php'] = $plugin_tpl->parse('themeconf', true);
+ /*
+ * Build mail-css.tpl
+ **/
+ $plugin_tpl->set_filenames(array('mailcss'=>
+ dirname(__FILE__) . '/mail-css.tpl2'));
+ $plugin_tpl->assign('main',$main);
+ $main['mail-css.tpl'] = $plugin_tpl->parse('mailcss', true);
// Smarty trace
$plugin_tpl->assign('main',$main);
@@ -229,6 +233,10 @@ if (isset($_POST['submit']) and (!is_adviser()))
imagedestroy ($dest);
}
+
+ /* All logic is there
+ * On "todo" : Create files and uncomment some previous statements.
+ */
$swift_theme_creator->save_theme_config();
@@ -318,4 +326,4 @@ $template->assign('main', $main);
$template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');
$swift_theme_creator->theme_config = $main;
$swift_theme_creator->save_theme_config();
-?> \ No newline at end of file
+?>