테스트 사이트 - 개발 중인 베타 버전입니다

index.php 파일에서 게시판을 바로 불러와서사용하려고 하는데.... 채택완료

<table width="900" border="0" align="center" cellpadding="0" cellspacing="0">

&nbsp; <tr>

&nbsp; &nbsp; <td height="3000"width="100%" colspan="3" align="center" valign="top">

<iframe name='ifmain' width='100%' height='100%' marginwidth='0' marginheight='0' hspace='0' vspace='0' frameborder='0' scrolling='no' src='/bbs/board.php?bo_table=P01'></iframe>

</td>

</tr>

</table>



해당 소스를 사용합니다.

그런데 height="3000" 이걸 100%로 화면이 줄어서 잘리더라구요. 그래서 3000으로 했는데

원래 무제한은 100% 아닌가요?



첨부는 100%로 했을때 캡쳐입니다. 전체가 다 보일줄 알았는데 그렇지가 않네요.

왜 그런지 모르겠습니다. 위 아래가 짤린거에요.







-----------------------추가--------------------------

해결 했는데 스크립트를 추가하면 되는거였네요.







<!--- 아이프레임자동으로늘어나는자바스크립 --->

<script language="JavaScript">

function reSize() {

&nbsp; &nbsp; try {

&nbsp; &nbsp; &nbsp; &nbsp; var objBody = auto_iframe.document.body;

&nbsp; &nbsp; &nbsp; &nbsp; var objFrame = document.all["auto_iframe"];

&nbsp; &nbsp; &nbsp; &nbsp; ifrmHeight = objBody.scrollHeight + (objBody.offsetHeight - objBody.clientHeight);

&nbsp; &nbsp; &nbsp; &nbsp; objFrame.style.height = ifrmHeight + "px";

&nbsp; &nbsp; }

&nbsp; &nbsp; &nbsp; &nbsp; catch(e) {}

}



function init_iframe() {

&nbsp; &nbsp; reSize();

&nbsp; &nbsp; setTimeout('init_iframe()',1)

}



init_iframe();

</script>

<!--- 아이프레임자동으로늘어나는자바스크립 끝--->





<!-- 게시판 아이프레임-->

<iframe src="게시판주소"&nbsp; frameborder="0" width="100%" allowtransparency="true"

name="auto_iframe" id="auto_iframe" marginwidth="0" marginheight="0" scrolling="No"></iframe>

&nbsp;<!-- 게시판 끝-->
댓글을 작성하려면 로그인이 필요합니다.

답변 2개

채택된 답변
+20 포인트
auto는 안되려나요?
로그인 후 평가할 수 있습니다

답변에 대한 댓글 1개

안되네요 ㅡㅡ;;;

댓글을 작성하려면 로그인이 필요합니다.

index.php의 용도를 특정게시판으로 틔우고 싶으시면 프레임 쓰지 마시고

그냥 해당 게시판으로 자동 넘기세요..

해당 게시판 상단이나 하단은 원하는 대로 꾸미면 되니까요.



index.php화일 내용을

<meta http-equiv="refresh" content='0;url=bbs/board.php?bo_table=P01'>이렇게 고치거나



<script>

<!--

location.href="bbs/board.php?bo_table=P01";

-->

</script>



또는



<?php

header("location:bbs/board.php?bo_table=P01");

?>



하시면 될 것 같네요.
로그인 후 평가할 수 있습니다

답변에 대한 댓글 3개

알려주신팁 정말 고맙습니다. 그런데 가운데 정렬이안되네요 ㅡㅡ;;;
<?php
header("location:bbs/board.php?bo_table=P01");
?>
이걸로 했습니다.
가운데 정렬은 그누보드 자체를 설치하셨다면 되어 있는데요..
스타일과 해더화일 부분을 잘 살펴보세요.
네 감사합니다. 한번 살펴 보겠습니다.

--- 해더 파일---
<?php
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가

include_once(G5_PATH.'/head.sub.php');
include_once(G5_LIB_PATH.'/latest.lib.php');
include_once(G5_LIB_PATH.'/outlogin.lib.php');
include_once(G5_LIB_PATH.'/poll.lib.php');
include_once(G5_LIB_PATH.'/visit.lib.php');
include_once(G5_LIB_PATH.'/connect.lib.php');
include_once(G5_LIB_PATH.'/popular.lib.php');

if (G5_IS_MOBILE) {
include_once(G5_MOBILE_PATH.'/head.php');
return;
}

// 상단 파일 경로 지정 : 이 코드는 가능한 삭제하지 마십시오.
if ($config['cf_include_head']) {
if (!@include_once($config['cf_include_head'])) {
die('기본환경 설정에서 상단 파일 경로가 잘못 설정되어 있습니다.');
}
return; // 이 코드의 아래는 실행을 하지 않습니다.
}
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>컴싹</title>
<style type="text/css">
<!--
body {
margin-top: 0px;
}
-->
</style></head>

<body>
<table width="800" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td height="100%" width="100%" colspan="3" align="center" valign="top">

댓글을 작성하려면 로그인이 필요합니다.

답변을 작성하려면 로그인이 필요합니다.

로그인

전체 질문 목록

🐛 버그신고