필

홈페이지를 중앙정렬로 하는방법좀 알려주세요.,

sir이나 네이버처럼 중앙정렬로 하고 싶은데..
방법을 모르겠네요 ;;
상세히좀 부탁드립니다.

댓글 8개

테이블 태그에 align="center"잡아주시면 되요~

<table align="center">
<tr>
<td></td>
</tr>
</table>
어느 파일에다가 그렇게 설정해주면 될까요?
인덱스 파일을 비롯 모든 페이지에 그렇게 해주셔야 모든 페이지가 중앙정렬이되요~
<table align="center">
<tr>
<td></td>
</tr>
</table>
테이블 맨위에 넣었는데 이렇게 뜹니다.


Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 47

Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 49

Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 50

Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 51

Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 52

Warning: Cannot modify header information - headers already sent by (output started at /home/hosting_users/sa/www/head.php:9) in /home/hosting_users/sa/www/head.sub.php on line 53
글 전체를 <div style="margin:0 auto"></div>로 싸주세요.

아니면 <body>아래에
<center>태그를 넣고
<div style="text-align:left;">라고 넣는 방법도 있습니다.
head.php
테이블 시작하는 곳 맨앞에
<center>를 붙여 주기만 하면 됩니다
head.php 에서
.
.
$table_width = 1000;
?>
<div align=center> <------------------------------------ 추가
<!-- 상단 배경 시작 -->

.
.
tail.php 에서
.
.
</table>
<!-- 카피라이트 끝 -->
</div> <----------------------------------------------- 추가
<?
include_once("$g4[path]/tail.sub.php");
?>
style.css에
#all{width:100%;text-align:center;} 추가해주시고
head.php 파일과 tail.php 파일에
<div id="all"></div>를 이용해서 한번 감싸주세요
댓글을 작성하시려면 로그인이 필요합니다.

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

+
제목 글쓴이 날짜 조회
09-09-17 조회 1,738
09-09-17 조회 1,026
09-09-17 조회 1,860
09-09-17 조회 1,053
09-09-17 조회 854
09-09-17 조회 3,470
09-09-17 조회 1,619
09-09-17 조회 1,331
09-09-17 조회 1,634
09-09-17 조회 1,642
09-09-17 조회 1,612
09-09-17 조회 1,072
09-09-17 조회 2,148
09-09-17 조회 872
09-09-17 조회 1,084
09-09-17 조회 840
09-09-17 조회 1,165
09-09-17 조회 1,998
09-09-17 조회 1,659
09-09-17 조회 1,077