if (is_checked('chk_all_insert_content')) { $all_fields .= " , bo_insert_content = '{$bo_insert_content}' "; } if (is_checked('chk_all_use_search')) { $all_fields .= " , bo_use_search = '{$bo_use_search}' "; } if (is_checked('chk_all_order')) { $all_fields .= " , bo_order = '{$bo_order}' "; } for ($i = 1; $i <= 10; $i++) { if (is_checked('chk_all_' . $i)) { $all_fields .= " , bo_{$i}_subj = '" . $_POST['bo_' . $i . '_subj'] . "' "; $all_fields .= " , bo_{$i} = '" . $_POST['bo_' . $i] . "' "; } } if ($all_fields) { sql_query(" update {$g5['board_table']} set bo_table = bo_table {$all_fields} "); } delete_cache_latest($bo_table); //외부이미지 전체 재수집 if (is_checked('as_save_all')) { $result = sql_query(" select wr_id, wr_content from {$g5['write_prefix']}{$bo_table} where wr_is_comment = '0' "); for ($i = 0; $row = sql_fetch_array($result); $i++) { if (!$row['wr_id'] || !$row['wr_content']) { continue; } $content = apms_content_image(addslashes($row['wr_content'])); sql_query(" update {$g5['write_prefix']}{$bo_table} set wr_content = '{$content}' where wr_id = '{$row['wr_id']}' "); } } goto_url("./board_form.php?w=u&bo_table={$bo_table}&{$qstr}");
$mb_id = ""; // 비회원의 경우 이름이 누락되는 경우가 있음 if (!trim($wr_name)) { alert("이름은 필히 입력하셔야 합니다."); } $wr_name = clean_xss_tags(trim($_POST['wr_name'])); $wr_email = get_email_address(trim($_POST['wr_email'])); } $sql_password = $wr_password ? " , wr_password = '******' " : ""; $sql_ip = ''; if (!$is_admin) { $sql_ip = " , wr_ip = '{$_SERVER['REMOTE_ADDR']}' "; } // 외부 이미지 저장 if ($board['as_save']) { $wr_content = apms_content_image($wr_content); } $sql = " update {$write_table}\n set ca_name = '{$ca_name}',\n wr_option = '{$html},{$secret},{$mail}',\n wr_subject = '{$wr_subject}',\n wr_content = '{$wr_content}',\n wr_link1 = '{$wr_link1}',\n wr_link2 = '{$wr_link2}',\n mb_id = '{$mb_id}',\n wr_name = '{$wr_name}',\n wr_email = '{$wr_email}',\n wr_homepage = '{$wr_homepage}',\n wr_1 = '{$wr_1}',\n wr_2 = '{$wr_2}',\n wr_3 = '{$wr_3}',\n wr_4 = '{$wr_4}',\n wr_5 = '{$wr_5}',\n wr_6 = '{$wr_6}',\n wr_7 = '{$wr_7}',\n wr_8 = '{$wr_8}',\n wr_9 = '{$wr_9}',\n wr_10 = '{$wr_10}',\n as_type = '{$as_type}',\n as_img = '{$as_img}',\n as_publish = '{$as_publish}',\n as_extra = '{$as_extra}',\n\t\t\t\t\t as_down = '{$as_down}',\n as_view = '{$as_view}',\n\t\t\t\t\t as_tag = '{$as_tag}',\n\t\t\t\t\t as_icon = '{$as_icon}',\n as_update = '{$as_update}'\n {$sql_ip}\n {$sql_password}\n where wr_id = '{$wr['wr_id']}' "; sql_query($sql); // 분류가 수정되는 경우 해당되는 코멘트의 분류명도 모두 수정함 // 코멘트의 분류를 수정하지 않으면 검색이 제대로 되지 않음 $sql = " update {$write_table} set ca_name = '{$ca_name}' where wr_parent = '{$wr['wr_id']}' "; sql_query($sql); /* if ($notice) { //if (!preg_match("/[^0-9]{0,1}{$wr_id}[\r]{0,1}/",$board['bo_notice'])) if (!in_array((int)$wr_id, $notice_array)) { $bo_notice = $wr_id . ',' . $board['bo_notice']; sql_query(" update {$g5['board_table']} set bo_notice = '{$bo_notice}' where bo_table = '{$bo_table}' "); } } else {