GetLoginPkid(); $LoginName = $webhelper->GetLoginName(); //LoginCheck $PageCode = "050101"; $sno = "7"; //설계사례 //$title = "설계사례"; $title = "설계사례"; $PageUrl = "/gallery/completion_case02.php"; $PageName = "completion_case02"; $b_cate = "건축갤러리 상담신청"; //상담카테고리 //Parameter $page = $webhelper->RequestFilter("page", 0, false); $sch_b_show = $webhelper->RequestFilter("sch_b_show", 20, false); $searchKey = $webhelper->RequestFilter("searchKey", -1, false); $pkid = $webhelper->RequestFilter("pkid", 0, false); $Parameter = "?page=$page&sch_b_show=$sch_b_show&searchKey=" . urlencode($searchKey); //Parameter Check if ($webhelper->isNull($page)) $page = 1; if ($webhelper->isNull($sch_b_show)) $sch_b_show = ""; if ($webhelper->isNull($searchKey)) $searchKey = ""; if ($webhelper->isNull($pkid)) $pkid = 0; $dbhelper->dbOpen(); //카테고리 $sql = "SELECT * FROM Web_board_set WHERE sno='$sno'"; $Cate = $dbhelper->RunSQLReturnOneRow($sql); if($Cate["bs_cate"] != "") $CateArray=explode("|",$Cate["bs_cate"]); if($pkid > 0) { $sql = "select * from Web_board_data d left join Web_member m on d.mb_uid = m.mb_uid left join Web_board_set s on d.sno=s.sno where bno = $pkid "; $View = $dbhelper->RunSQLReturnOneRow($sql); $ViewCateArray = explode("|",$View["b_cate"]); $ViewEtc3Array = explode("|",$View["b_etc3"]); $sql = "select * from Web_board_file where bf_kind = 'board' and bno = ". $pkid ." order by bfno asc, bf_datetime desc"; $ViewFileList = $dbhelper->RunSQLReturnRows($sql); $sql = "select * from Web_board_comment where bno = ". $pkid ." order by Bc_step , bc_step_reply"; $ViewCommentList = $dbhelper->RunSQLReturnRows($sql); } $dbhelper->dbClose(); if($ViewFileList != null && count($ViewFileList) > 0) { $i = 0; foreach ($ViewFileList as $row){ if ( $row["bf_file"] ) { $str = ""; $tmp = $webhelper->GetImageExplode( $row["bf_file"] ); $row['file'] = "/common/download.php?code=".$View['bs_code']."&pkid=".$View['bno']; //$str .= "add_file(\"

{$row[bf_source]} (파일 삭제시 체크 박스를 클릭해 주세요.)

"; //$imgarr=array('gif','jpg','png','JPG','PNG','GIF','jpeg'); //$Thumb="/FileData/".$View['bs_code']."/simg/list_".$row['bf_file']; //if(in_array($tmp[1],$imgarr)) $str .="
"; //$str .= "\");\n"; //$str .= "

{$row["bf_source"]} (파일 삭제시 체크 박스를 클릭해 주세요.)

"; //$imgarr=array('gif','jpg','png','JPG','PNG','GIF','jpeg'); //$Thumb="/FileData/".$View['bs_code']."/simg/list_".$row['bf_file']; //if(in_array($tmp[1],$imgarr)) $str .="
"; $str .= "

{$row["bf_source"]} (파일 삭제시 체크 박스를 클릭해 주세요.)

"; $imgarr=array('gif','jpg','png','JPG','PNG','GIF','jpeg'); $Thumb="/FileData/".$View['bs_code']."/".$row['bf_file']; if ( $i == 0 ) $Thumb2="/FileData/".$View['bs_code']."/simg/list_".$row['bf_file']; else if ( $i == 1 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; else if ( $i == 2 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; else if ( $i == 3 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; else if ( $i == 4 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; else if ( $i == 5 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; else if ( $i == 22 ) $Thumb2="/FileData/".$View['bs_code']."/simg/view_".$row['bf_file']; if(in_array($tmp[1],$imgarr)) $str2 = $str."
"; if(in_array($tmp[1],$imgarr)) $str .="
"; //$View['afile'.$i] = $str; //$View['thumb_afile'.$i] = $str2; //$is_file = $str; if ( $row["bfno"] == 0 ) $is_thumb0 = $str; //썸네일 if ( $row["bfno"] == 1 ) $is_thumb1 = $str; //메인썸네일 if ( $row["bfno"] == 2 ) $is_thumb2 = $str; //메인베스트썸네일 if ( $row["bfno"] == 3 ) $is_thumb3 = $str; // if ( $row["bfno"] == 4 ) $is_thumb4 = $str; // if ( $row["bfno"] == 5 ) $is_thumb5= $str; // if ( $row["bfno"] == 22 ) $is_thumb22 = $str; // if ( $row["bfno"] == 1 ) $MainImg = "/FileData/".$View['bs_code']."/".$row['bf_file']; //메인썸네일 } else { $str .= "add_file('');\n"; } $i++; } } else { //$str .= "add_file('');\n"; } ?> 윤성하우징