어떤 문제일까요? Warning: Cannot modify header information > 그누4 질문답변

그누4 질문답변

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기
기존 게시물은 열람만 가능합니다.

어떤 문제일까요? Warning: Cannot modify header information 정보

질문 어떤 문제일까요? Warning: Cannot modify header information

본문

Warning: Cannot modify header information - headers already sent by (output started at /home/계정명/index.php:2) in /home/계정명/gnu/lib/common.lib.php on line 96
  • 복사

댓글 전체

헤더 정보가 두 번 전달되었다는 것입니다.

위의 index.php와 본 디렉토리의 head.sub.php, head.php 이 세 파일들을 열고서, 아래의 것을 찾고서, 하나씩 주석 마크("//")를 넣어가며, 저장 후 테스트 해 보면서 체크해 보십시오.

header("Content-Type: text/html; charset=$g4[charset]");
$gmnow = gmdate("D, d M Y H:i:s") . " GMT";
header("Expires: 0"); // rfc2616 - Section 14.21
header("Last-Modified: " . $gmnow);
header("Cache-Control: no-store, no-cache, must-revalidate"); // HTTP/1.1
header("Cache-Control: pre-check=0, post-check=0, max-age=0"); // HTTP/1.1
header("Pragma: no-cache"); // HTTP/1.0
이 중에 제일 먼저 선언되는 것은 head.sub.php입니다.

가능하면 이 파일은 그냥 두고서, 다른 파일에서 header(....)로 시작하는 문장이 겹쳐서 나타나지 않나 보고서 주석 처리하시던지, 그 라인을 지워주세요.
© SIRSOFT
현재 페이지 제일 처음으로