꽈

head.sub.php에 DTD를 추가하면 에러납니다

div로 만든 레이아웃이 깨져서 head.sub.php의 첫번째 줄에

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

이런식으로 DTD를 추가하면

아래 메시지가 나옵니다.
Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 33

Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 35

Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 36

Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 37

Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 38

Warning: Cannot modify header information - headers already sent by (output started at F:\APM_Setup\htdocs\red2t\head.sub.php:2) in F:\APM_Setup\htdocs\red2t\head.sub.php on line 39

아래 코드가 33-39줄의 내용입니다.
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

뭐가 잘못되서 에러가 나는 걸까요.
그누보드4는 DTD 설정을 할 수 없나요?

댓글 2개

<head>~</head>사이에 넣으시면됩니다
40줄 쯤에
<!-- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> -->
이렇게 된 부분이 있을거에요. 이부분 대신 넣어보세요.
댓글을 작성하시려면 로그인이 필요합니다.

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

+
제목 글쓴이 날짜 조회
09-11-11 조회 1,629
09-11-10 조회 919
09-11-10 조회 1,103
09-11-10 조회 1,054
09-11-10 조회 889
09-11-10 조회 1,065
09-11-10 조회 1,600
09-11-10 조회 1,589
09-11-10 조회 911
09-11-10 조회 912
09-11-10 조회 1,044
09-11-10 조회 1,088
09-11-10 조회 1,610
09-11-10 조회 1,133
09-11-10 조회 934
09-11-10 조회 1,632
09-11-10 조회 1,014
09-11-10 조회 1,050
09-11-09 조회 947
09-11-09 조회 3,311