From 817a82a1afb86a1761c5c6a810ed9b8f599c147a Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Sun, 1 Jul 2007 11:25:48 +0000 Subject: [PATCH] different approach actually git-svn-id: file:///svn/phpbb/trunk@7817 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/acp/acp_styles.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/phpBB/includes/acp/acp_styles.php b/phpBB/includes/acp/acp_styles.php index 1ef80c34b1..a7e7889480 100644 --- a/phpBB/includes/acp/acp_styles.php +++ b/phpBB/includes/acp/acp_styles.php @@ -2166,16 +2166,19 @@ parse_css_file = {PARSE_CSS_FILE} $db->sql_query($sql); } } - else if (!$store_db && !$safe_mode) - { - $store_db = 1; - $error[] = $user->lang['EDIT_TEMPLATE_STORED_DB']; - } else if ($store_db) { $filelist = filelist("{$phpbb_root_path}styles/{$style_row['template_path']}/template", '', 'html'); $this->store_templates('insert', $style_id, $style_row['template_path'], $filelist); } + else + { + // We no longer store within the db, but are also not able to update the file structure + // Since the admin want to switch this, we adhere to his decision. But we also need to remove the cache + $sql = 'DELETE FROM ' . STYLES_TEMPLATE_DATA_TABLE . " + WHERE template_id = $style_id"; + $db->sql_query($sql); + } $sql_ary += array( 'template_storedb' => $store_db,