diff --git a/phpBB/includes/acp/acp_styles.php b/phpBB/includes/acp/acp_styles.php index 4ab4420e6f..1ef80c34b1 100644 --- a/phpBB/includes/acp/acp_styles.php +++ b/phpBB/includes/acp/acp_styles.php @@ -739,6 +739,8 @@ parse_css_file = {PARSE_CSS_FILE} // destroy the cached version of the template (filename without extension) $this->clear_template_cache($template_info, array(substr($template_file, 0, -5))); + $cache->destroy('sql', STYLES_TABLE); + add_log('admin', 'LOG_TEMPLATE_EDIT', $template_info['template_name'], $template_file); trigger_error($user->lang['TEMPLATE_FILE_UPDATED'] . $additional . adm_back_link($this->u_action . "&action=edit&id=$template_id&text_rows=$text_rows&template_file=$template_file")); } @@ -2164,6 +2166,11 @@ 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');