aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/acp
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2007-08-15 17:32:48 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2007-08-15 17:32:48 +0000
commit2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169 (patch)
tree3dbeba19d89b737a07cf7cc23b8c4693d35234ea /phpBB/includes/acp
parent3ada3b76f0ce86274647758db029d84a0f404886 (diff)
downloadforums-2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169.tar
forums-2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169.tar.gz
forums-2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169.tar.bz2
forums-2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169.tar.xz
forums-2bbd2fb1f97d4668e82c26badbe89c3d3fdc8169.zip
some bugs fixed
git-svn-id: file:///svn/phpbb/trunk@8033 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/acp')
-rw-r--r--phpBB/includes/acp/acp_language.php2
-rw-r--r--phpBB/includes/acp/acp_profile.php4
-rw-r--r--phpBB/includes/acp/acp_styles.php20
3 files changed, 11 insertions, 15 deletions
diff --git a/phpBB/includes/acp/acp_language.php b/phpBB/includes/acp/acp_language.php
index ff827c5141..b59729c873 100644
--- a/phpBB/includes/acp/acp_language.php
+++ b/phpBB/includes/acp/acp_language.php
@@ -163,7 +163,7 @@ class acp_language
case 'download_file':
case 'upload_data':
- if (!$lang_id || empty($_POST['entry']))
+ if (!$lang_id || empty($_POST['entry']) || !is_array($_POST['entry']))
{
trigger_error($user->lang['NO_LANG_ID'] . adm_back_link($this->u_action), E_USER_WARNING);
}
diff --git a/phpBB/includes/acp/acp_profile.php b/phpBB/includes/acp/acp_profile.php
index 3b70b716b4..00f8d64acb 100644
--- a/phpBB/includes/acp/acp_profile.php
+++ b/phpBB/includes/acp/acp_profile.php
@@ -492,11 +492,11 @@ class acp_profile
}
}
}
- else if ($field_type == FIELD_BOOL && $key == 'field_default_value')
+ /* else if ($field_type == FIELD_BOOL && $key == 'field_default_value')
{
// Get the number of options if this key is 'field_maxlen'
$var = request_var('field_default_value', 0);
- }
+ }*/
$cp->vars[$key] = $var;
}
diff --git a/phpBB/includes/acp/acp_styles.php b/phpBB/includes/acp/acp_styles.php
index 45e0ed35d1..300e795f3b 100644
--- a/phpBB/includes/acp/acp_styles.php
+++ b/phpBB/includes/acp/acp_styles.php
@@ -666,10 +666,8 @@ parse_css_file = {PARSE_CSS_FILE}
$filelist = $filelist_cats = array();
- // we want newlines no carriage returns!
- $_POST['template_data'] = (isset($_POST['template_data']) && !empty($_POST['template_data'])) ? str_replace(array("\r\n", "\r"), array("\n", "\n"), $_POST['template_data']) : '';
-
- $template_data = (STRIP) ? stripslashes($_POST['template_data']) : $_POST['template_data'];
+ $template_data = utf8_normalize_nfc(request_var('template_data', '', true));
+ $template_data = htmlspecialchars_decode($template_data);
$template_file = utf8_normalize_nfc(request_var('template_file', '', true));
$text_rows = max(5, min(999, request_var('text_rows', 20)));
$save_changes = (isset($_POST['save'])) ? true : false;
@@ -871,7 +869,7 @@ parse_css_file = {PARSE_CSS_FILE}
'SELECTED_TEMPLATE' => $template_info['template_name'],
'TEMPLATE_FILE' => $template_file,
- 'TEMPLATE_DATA' => htmlspecialchars($template_data),
+ 'TEMPLATE_DATA' => utf8_htmlspecialchars($template_data),
'TEXT_ROWS' => $text_rows)
);
}
@@ -1021,11 +1019,9 @@ parse_css_file = {PARSE_CSS_FILE}
$filelist = $filelist_cats = array();
- // we want newlines no carriage returns!
- $_POST['template_data'] = (isset($_POST['template_data']) && !empty($_POST['template_data'])) ? str_replace(array("\r\n", "\r"), array("\n", "\n"), $_POST['template_data']) : '';
-
- $theme_data = (STRIP) ? stripslashes($_POST['template_data']) : $_POST['template_data'];
- $theme_file = utf8_normalize_nfc(request_var('template_file', '', true));
+ $theme_data = utf8_normalize_nfc(request_var('template_data', '', true));
+ $theme_data = htmlspecialchars_decode($theme_data);
+ $theme_file = utf8_normalize_nfc(request_var('template_file', '', true));
$text_rows = max(5, min(999, request_var('text_rows', 20)));
$save_changes = (isset($_POST['save'])) ? true : false;
@@ -1040,7 +1036,7 @@ parse_css_file = {PARSE_CSS_FILE}
if (!($theme_info = $db->sql_fetchrow($result)))
{
- trigger_error($user->lang['NO_THEME'] . adm_bacl_link($this->u_action), E_USER_WARNING);
+ trigger_error($user->lang['NO_THEME'] . adm_back_link($this->u_action), E_USER_WARNING);
}
$db->sql_freeresult($result);
@@ -1188,7 +1184,7 @@ parse_css_file = {PARSE_CSS_FILE}
'SELECTED_TEMPLATE' => $theme_info['theme_name'],
'TEMPLATE_FILE' => $theme_file,
- 'TEMPLATE_DATA' => htmlspecialchars($theme_data),
+ 'TEMPLATE_DATA' => utf8_htmlspecialchars($theme_data),
'TEXT_ROWS' => $text_rows)
);
}