Merge branch 'g4s'
This commit is contained in:
@ -76,7 +76,7 @@ for ($i=count($tmp_array)-1; $i>=0; $i--)
|
||||
|
||||
// 나라오름님 수정 : 원글과 코멘트수가 정상적으로 업데이트 되지 않는 오류를 잡아 주셨습니다.
|
||||
//$sql = " select wr_id, mb_id, wr_comment from {$write_table} where wr_parent = '{$write[wr_id]}' order by wr_id ";
|
||||
$sql = " select wr_id, mb_id, wr_is_comment from $write_table where wr_parent = '{$write['wr_id']}' order by wr_id ";
|
||||
$sql = " select wr_id, mb_id, wr_is_comment, wr_content from $write_table where wr_parent = '{$write['wr_id']}' order by wr_id ";
|
||||
$result = sql_query($sql);
|
||||
while ($row = sql_fetch_array($result))
|
||||
{
|
||||
|
||||
@ -97,7 +97,7 @@ while ($row = sql_fetch_array($result))
|
||||
{
|
||||
// 원본파일을 복사하고 퍼미션을 변경
|
||||
@copy($src_dir.'/'.$row3['bf_file'], $dst_dir.'/'.$row3['bf_file']);
|
||||
@chmod($dst_dir/$row3['bf_file'], 0606);
|
||||
@chmod($dst_dir/$row3['bf_file'], G4_FILE_PERMISSION);
|
||||
}
|
||||
|
||||
$sql = " insert into {$g4['board_file_table']}
|
||||
|
||||
@ -114,11 +114,11 @@ if (isset($_FILES['mb_icon']) && is_uploaded_file($_FILES['mb_icon']['tmp_name']
|
||||
if (preg_match("/(\.gif)$/i", $_FILES['mb_icon']['name'])) {
|
||||
// 아이콘 용량이 설정값보다 이하만 업로드 가능
|
||||
if ($_FILES['mb_icon']['size'] <= $config['cf_member_icon_size']) {
|
||||
@mkdir($mb_dir, 0707);
|
||||
@chmod($mb_dir, 0707);
|
||||
@mkdir($mb_dir, G4_DIR_PERMISSION);
|
||||
@chmod($mb_dir, G4_DIR_PERMISSION);
|
||||
$dest_path = $mb_dir.'/'.$mb_id.'.gif';
|
||||
move_uploaded_file($_FILES['mb_icon']['tmp_name'], $dest_path);
|
||||
chmod($dest_path, 0606);
|
||||
chmod($dest_path, G4_FILE_PERMISSION);
|
||||
if (file_exists($dest_path)) {
|
||||
//=================================================================\
|
||||
// 090714
|
||||
|
||||
@ -175,8 +175,8 @@ if (!isset($_POST['wr_subject']) || !trim($_POST['wr_subject']))
|
||||
alert('제목을 입력하여 주십시오.');
|
||||
|
||||
// 디렉토리가 없다면 생성합니다. (퍼미션도 변경하구요.)
|
||||
@mkdir(G4_DATA_PATH.'/file/'.$bo_table, 0707);
|
||||
@chmod(G4_DATA_PATH.'/file/'.$bo_table, 0707);
|
||||
@mkdir(G4_DATA_PATH.'/file/'.$bo_table, G4_DIR_PERMISSION);
|
||||
@chmod(G4_DATA_PATH.'/file/'.$bo_table, G4_DIR_PERMISSION);
|
||||
|
||||
$chars_array = array_merge(range(0,9), range('a','z'), range('A','Z'));
|
||||
|
||||
@ -276,7 +276,7 @@ for ($i=0; $i<count($_FILES['bf_file']['name']); $i++) {
|
||||
$error_code = move_uploaded_file($tmp_file, $dest_file) or die($_FILES['bf_file']['error'][$i]);
|
||||
|
||||
// 올라간 파일의 퍼미션을 변경합니다.
|
||||
chmod($dest_file, 0606);
|
||||
chmod($dest_file, G4_FILE_PERMISSION);
|
||||
}
|
||||
}
|
||||
|
||||
@ -557,7 +557,7 @@ $row = sql_fetch(" select count(*) as cnt from {$g4['board_file_table']} where b
|
||||
sql_query(" update {$write_table} set wr_file = '{$row['cnt']}' where wr_id = '{$wr_id}' ");
|
||||
|
||||
// 자동저장된 레코드를 삭제한다.
|
||||
sql_query(" delete from g4s_autosave where as_uid = '{$uid}' ");
|
||||
sql_query(" delete from {$g4['autosave_table']} where as_uid = '{$uid}' ");
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// 비밀글이라면 세션에 비밀글의 아이디를 저장한다. 자신의 글은 다시 패스워드를 묻지 않기 위함
|
||||
|
||||
Reference in New Issue
Block a user