real_escape_string($sword_raw); $sword = $_REQUEST['sword']; $scale = 20; // 1페이지당 자료수 $c_page = max(1, (int)($_REQUEST['c_page'] ?? 1)); $cate1_url = param_url('cate1', $cate1); $cate2_url = param_url('cate2', $cate2); $cate3_url = param_url('cate3', $cate3); $sword_url = param_url('sword', $sword); $sw_url = param_url('sw', $sw); $sql = " from board "; $whereq = " where is_del='N' "; if($cate1 != "") $whereq .= " and cate1 = '$cate1' "; if($cate2 != "") $whereq .= " and cate2 = '$cate2' "; if($cate3 != "") $whereq .= " and cate3 = '$cate3' "; $sql_notice = " Select * $sql $whereq and is_notice='Y' order by idx desc "; $result_notice = mysqli_query($con, $sql_notice) or die("DB Error"); $whereq_alarm = " WHERE is_del='N' "; if ($cate1 != "") $whereq_alarm .= " AND cate1 = '$cate1' "; if ($cate2 != "") $whereq_alarm .= " AND cate2 = '$cate2' "; $sql_alarm = " Select * $sql $whereq_alarm and is_notice='A' order by idx desc "; $result_alarm = mysqli_query($con, $sql_alarm) or die("DB Error"); $whereq .= " and is_notice = 'N' "; if($sword != "") { if($sw != "") $whereq .= " and ( $sw like '%$sword%' ) "; else $whereq .= " and ( ( title like '%$sword%') or ( cont like '%$sword%') ) "; } if($sword != "" && $sw != "") $whereq .= " and $sw like '%$sword%' "; if($s_date != "") { if($e_date != "") $whereq .= " and ( left(wdate,8) between '$s_date' and '$e_date') "; else $whereq .= " and left(wdate,8) >= '$s_date' "; } else { if($e_date != "") $whereq .= " and left(wdate,8) <= '$e_date' "; } $page_list_scale = 10; // 페이지 리스트 수 $list_total = mysql_one_data($DB_name,"Select count(*) $sql $whereq "); If (!$c_page) $c_page = 1; If (!$_no) $_no = 0; $last_page = floor($list_total/$scale); If ($last_page != $list_total/$scale) $last_page++; $start_article = ($c_page-1)*$scale; $ord = " idx_main desc, idx_main_depth asc, idx desc "; $query = "Select * $sql $whereq order by $ord Limit $start_article, $scale"; $result = mysqli_query($con, $query) or die("DB Error"); $_seq = $list_total - ($c_page - 1) * $scale; $_no = ($c_page - 1) * $scale; //$page_para = "cate3=$cate3&cate1=$cate1&scale=$scale&sw=$sw&sword=$sword&cate2=$cate2"; $page_para = "scale=$scale$cate2_url$cate3_url$sw_url$sword_url"; ?>
    = 100) $cnt_comment_disp = "99+"; else $cnt_comment_disp = $temp_notice["cnt_comment"]; $title = str_replace($sword,"$sword",$temp_notice["title"]); $image_url = $temp_notice["filename1_path"]; $user_level = memLevelIcon($temp_notice["idx_write"]); // 오늘 올린 자료의 날짜를 색칠하기 위해 $txt_date = strlen(changeDate($temp_notice["wdate"],"M")); if($txt_date <= 6){ $txt_date_class = "txt_today"; } ?>
  • 공지

    []

    추천

    조회

  • = 100) $cnt_comment_disp = "99+"; else $cnt_comment_disp = $temp_alarm["cnt_comment"]; $title = str_replace($sword,"$sword",$temp_alarm["title"]); $image_url = $temp_alarm["filename1_path"]; $user_level = memLevelIcon($temp_alarm["idx_write"]); // 오늘 올린 자료의 날짜를 색칠하기 위해 $txt_date = strlen(changeDate($temp_alarm["wdate"],"M")); if($txt_date <= 6){ $txt_date_class = "txt_today"; } ?>
  • 알림

    []

    추천

    조회

  • $sword",$temp["title"]); // 썸네일 처리 if (!empty($temp["thumbnail_file"])) { $image_url = $temp["thumbnail_file"]; } else { $image_url = $temp["filename1_path"]; } if( $temp["cnt_comment"] >= 100) $cnt_comment_disp = "99+"; else $cnt_comment_disp = $temp["cnt_comment"]; // 댓글 수 0이면 댓글 안보이게 if($cnt_comment_disp == 0){ $commnet_zero = "commnet_zero"; }else{ $commnet_zero = ''; } $user_level = memLevelIcon($temp["idx_write"]); $title = str_replace($sword,"$sword",$temp["title"]); // // 오늘 올린 자료의 날짜를 색칠하기 위해 $txt_date = strlen(changeDate($temp["wdate"],"M")); if($txt_date <= 6){ $txt_date_class = "txt_today"; }else{ $txt_date_class = ""; } ?>
  • 해당 카테고리에 글이 등록되지 않았습니다.
0) pagelist_user ($PHP_SELF,$last_page,$c_page,$page_list_scale,$page_para); ?>
📝글쓰기
검색