Zeile 293 | Zeile 293 |
---|
}
// do some type filtering
|
}
// do some type filtering
|
$mybb->input['type'] = str_replace("\n", "", $mybb->input['type']); if(strtolower(substr($mybb->input['type'], 0, 3)) == "php")
| $mybb->input['type'] = $mybb->get_input('type'); if(!ctype_alnum($mybb->input['type']) || strtolower($mybb->input['type']) == "php")
|
{ $mybb->input['type'] = ""; }
| { $mybb->input['type'] = ""; }
|
Zeile 306 | Zeile 306 |
---|
if(!$errors) {
|
if(!$errors) {
|
if($mybb->input['type'] == "custom") { $options_code = $mybb->input['extra']; } else if($mybb->input['extra'])
| if($mybb->input['extra'])
|
{ $options_code = "{$mybb->input['type']}\n{$mybb->input['extra']}"; }
| { $options_code = "{$mybb->input['type']}\n{$mybb->input['extra']}"; }
|
Zeile 399 | Zeile 395 |
---|
if(!empty($lang->$group_lang_var)) { $options[$group['gid']] = htmlspecialchars_uni($lang->$group_lang_var);
|
if(!empty($lang->$group_lang_var)) { $options[$group['gid']] = htmlspecialchars_uni($lang->$group_lang_var);
|
}
| }
|
else { $options[$group['gid']] = htmlspecialchars_uni($group['title']);
| else { $options[$group['gid']] = htmlspecialchars_uni($group['title']);
|
Zeile 453 | Zeile 449 |
---|
// Editing a particular setting if($mybb->input['action'] == "edit")
|
// Editing a particular setting if($mybb->input['action'] == "edit")
|
{ $query = $db->simple_select("settings", "*", "sid='".$mybb->get_input('sid', MyBB::INPUT_INT)."'"); $setting = $db->fetch_array($query);
| { $query = $db->simple_select("settings", "*", "sid='".$mybb->get_input('sid', MyBB::INPUT_INT)."'"); $setting = $db->fetch_array($query);
|
// Does the setting not exist? if(!$setting['sid']) {
| // Does the setting not exist? if(!$setting['sid']) {
|
Zeile 500 | Zeile 496 |
---|
}
// do some type filtering
|
}
// do some type filtering
|
$mybb->input['type'] = str_replace("\n", "", $mybb->input['type']); if(strtolower(substr($mybb->input['type'], 0, 3)) == "php")
| $mybb->input['type'] = $mybb->get_input('type'); if(!ctype_alnum($mybb->input['type']) || strtolower($mybb->input['type']) == "php")
|
{ $mybb->input['type'] = ""; }
| { $mybb->input['type'] = ""; }
|
Zeile 512 | Zeile 508 |
---|
}
if(!$errors)
|
}
if(!$errors)
|
{ if($mybb->input['type'] == "custom") { $options_code = $mybb->input['extra']; } else if($mybb->input['extra'])
| { if($mybb->input['extra'])
|
{ $options_code = "{$mybb->input['type']}\n{$mybb->input['extra']}"; }
| { $options_code = "{$mybb->input['type']}\n{$mybb->input['extra']}"; }
|
Zeile 553 | Zeile 545 |
---|
$db->update_query("settings", $updated_setting, "sid='{$setting['sid']}'"); rebuild_settings();
|
$db->update_query("settings", $updated_setting, "sid='{$setting['sid']}'"); rebuild_settings();
|
|
|
// Log admin action log_admin_action($setting['sid'], $mybb->input['title']);
| // Log admin action log_admin_action($setting['sid'], $mybb->input['title']);
|
Zeile 589 | Zeile 581 |
---|
$page->output_nav_tabs($sub_tabs, 'modify_setting');
$form = new Form("index.php?module=config-settings&action=edit", "post", "edit");
|
$page->output_nav_tabs($sub_tabs, 'modify_setting');
$form = new Form("index.php?module=config-settings&action=edit", "post", "edit");
|
|
|
echo $form->generate_hidden_field("sid", $setting['sid']);
|
echo $form->generate_hidden_field("sid", $setting['sid']);
|
|
|
if($errors)
|
if($errors)
|
{
| {
|
$setting_data = $mybb->input; $page->output_inline_error($errors); }
| $setting_data = $mybb->input; $page->output_inline_error($errors); }
|
Zeile 606 | Zeile 598 |
---|
if(isset($type[1])) { $setting_data['extra'] = trim($type[1]);
|
if(isset($type[1])) { $setting_data['extra'] = trim($type[1]);
|
} }
| } }
|
$form_container = new FormContainer($lang->modify_setting); $form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $setting_data['title'], array('id' => 'title')), 'title');
| $form_container = new FormContainer($lang->modify_setting); $form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $setting_data['title'], array('id' => 'title')), 'title');
|
Zeile 676 | Zeile 668 |
---|
// Delete Setting if($mybb->input['action'] == "delete")
|
// Delete Setting if($mybb->input['action'] == "delete")
|
{
| {
|
$query = $db->simple_select("settings", "*", "sid='".$mybb->get_input('sid', MyBB::INPUT_INT)."'"); $setting = $db->fetch_array($query);
| $query = $db->simple_select("settings", "*", "sid='".$mybb->get_input('sid', MyBB::INPUT_INT)."'"); $setting = $db->fetch_array($query);
|
Zeile 748 | Zeile 740 |
---|
$sid = (int)$sid; $update_setting = array('disporder' => (int)$new_order); $db->update_query("settings", $update_setting, "sid={$sid}");
|
$sid = (int)$sid; $update_setting = array('disporder' => (int)$new_order); $db->update_query("settings", $update_setting, "sid={$sid}");
|
} }
$plugins->run_hooks("admin_config_settings_manage_commit");
| } }
$plugins->run_hooks("admin_config_settings_manage_commit");
|
// Log admin action log_admin_action();
| // Log admin action log_admin_action();
|
Zeile 1291 | Zeile 1283 |
---|
{ my_unsetcookie("adminsid"); $mybb->settings['cookieprefix'] = $mybb->input['upsetting']['cookieprefix'];
|
{ my_unsetcookie("adminsid"); $mybb->settings['cookieprefix'] = $mybb->input['upsetting']['cookieprefix'];
|
my_setcookie("adminsid", $admin_session['sid'], '', true, "lax");
| my_setcookie("adminsid", $admin_session['sid'], '', true, "strict");
|
}
if(isset($mybb->input['upsetting']['statstopreferrer']) && $mybb->input['upsetting']['statstopreferrer'] != $mybb->settings['statstopreferrer'])
| }
if(isset($mybb->input['upsetting']['statstopreferrer']) && $mybb->input['upsetting']['statstopreferrer'] != $mybb->settings['statstopreferrer'])
|
Zeile 1411 | Zeile 1403 |
---|
{ $groupinfo['title'] = $lang->$group_lang_var; }
|
{ $groupinfo['title'] = $lang->$group_lang_var; }
|
| $groupinfo['title'] = htmlspecialchars_uni($groupinfo['title']);
|
// Page header $page->add_breadcrumb_item($groupinfo['title']);
| // Page header $page->add_breadcrumb_item($groupinfo['title']);
|
Zeile 1453 | Zeile 1447 |
---|
if(isset($lang->$group_lang_var)) { $groupinfo['title'] = $lang->$group_lang_var;
|
if(isset($lang->$group_lang_var)) { $groupinfo['title'] = $lang->$group_lang_var;
|
}
$form_container = new FormContainer($groupinfo['title']);
| }
$groupinfo['title'] = htmlspecialchars_uni($groupinfo['title']);
$form_container = new FormContainer($groupinfo['title']);
|
if(empty($cache_settings[$groupinfo['gid']])) {
| if(empty($cache_settings[$groupinfo['gid']])) {
|
Zeile 1470 | Zeile 1466 |
---|
foreach($cache_settings[$groupinfo['gid']] as $setting) {
|
foreach($cache_settings[$groupinfo['gid']] as $setting) {
|
| $setting['name'] = htmlspecialchars_uni($setting['name']);
|
$options = ""; $type = explode("\n", $setting['optionscode']); $type[0] = trim($type[0]);
| $options = ""; $type = explode("\n", $setting['optionscode']); $type[0] = trim($type[0]);
|