아

iframe자동높이조절문제...(파이어폭스만이상하게 나오네요)ㅠㅠ

<script language="javascript">
function calcHeight(FrameName) {
   var the_height= document.getElementById(FrameName).contentWindow.document.body.scrollHeight;
document.getElementById(FrameName).height=the_height;
}
</script>

<iframe id="board_products_id" frameborder="1" src="1.php" onLoad="calcHeight('board_products_id')" width="100%" height="100%" scrolling="no" title="board_products" ></a>
</iframe>

이렇게 쓰고있는데요..
IE, 크롬이나 다른곳은 정상적으로 나오는데..
파이어폭스가 자동조절이 않됩니다.(파폭 버전 3.6.16)
무엇이 문제라서..ㅠㅠ
고수님들 한수갈켜주세요..

|

댓글 2개

$('#board_products_id').load(function() {
$(this).height($(this).contents().find('body')[0].scrollHeight);
});

어차피 불러온 덩치큰놈 써먹어야죠
간단히 아래처럼 해보세요
<iframe src="1.php" name="content" onload="this.height=content.document.body.scrollHeight;" width="100%" height="100%" marginwidth="0" marginheight="0" frameborder="no" scrolling="no"></iframe>
댓글을 작성하시려면 로그인이 필요합니다.

자유게시판

203,302건
+
제목 글쓴이 날짜 조회
11-04-06 조회 1,886
11-04-06 조회 1,413
11-04-06 조회 2,152
11-04-06 조회 1,971
11-04-06 조회 1,469
11-04-06 조회 1,952
11-04-06 조회 2,340
11-04-06 조회 2,213
11-04-06 조회 2,155
11-04-06 조회 1,998
11-04-06 조회 2,016
11-04-06 조회 4,401
11-04-06 조회 2,168
11-04-06 조회 2,147
11-04-06 조회 3,577
11-04-06 조회 2,777
11-04-06 조회 1,862
11-04-06 조회 2,843
11-04-06 조회 2,215
11-04-06 조회 1,971