답변 2개
채택된 답변
+20 포인트
답변에 대한 댓글 1개
h
humanb2box
5년 전
댓글을 작성하려면 로그인이 필요합니다.
5년 전
/* 그누보드게시판 엑셀저장 - GIT(www.g-it.kr) */
include_once("./common.php");</p>
<p>set_time_limit(0);
$g5[title] = "엑셀 문서 다운로드";
header("Pragma: public");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Expires: 0");
header("Content-type: application/vnd.ms-excel" );
header("Content-Type: application/vnd.ms-excel; charset=utf-8");
header("Content-Disposition: attachment; filename=db".date('Y-m-d').".xls" );
header("Content-Description: PHP5 Generated Data");</p>
<p>$result=@sql_query("select * from {$g5['db_table']} where wr_is_comment='0' order by wr_datetime");
?> </p>
<p><html>
<head>
<title><?=$g5[title]?></title>
<meta http-equiv="Content-Type" content="application/vnd.ms-excel;charset=utf-8">
</head> </p>
<p><body>
<table width="100%" cellpadding="0" cellspacing="0" border="1"> </p>
<p><?
$i = 0;
while($data=sql_fetch_array($result)) {
echo "
<tr style='height:30px;text-align:center;'>
<td>$i</td>
<td>$data[wr_name]</td>
<td>$data[wr_1]</td>
<td>$data[wr_2]</td>
<td>$data[wr_3]</td>
<td>$data[wr_10]</td>
<td>$data[wr_datetime]</td>
</tr>";
$i++;
} // while end
?>
</table>
</body>
</html></p>
<p>
로그인 후 평가할 수 있습니다
답변에 대한 댓글 1개
�
날고픈쭈니
5년 전
소스상으로는 문제는 없어보이네요..
서버상에서 제한하는지, mysql에서 제한하는지 여러가지 체크해봐야할듯합니다.
우선 쿼리를
select * from {$g5['db_table']} where wr_is_comment='0' order by wr_datetime limit 0,10000
으로 수정해서 해봐주세요.
서버상에서 제한하는지, mysql에서 제한하는지 여러가지 체크해봐야할듯합니다.
우선 쿼리를
select * from {$g5['db_table']} where wr_is_comment='0' order by wr_datetime limit 0,10000
으로 수정해서 해봐주세요.
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인
날짜데이터만 봅으면 정상으로 나옵니당.. 감사합니다 ㅎㅎ