frame에서 target=_top 사용하기 > 그누4 팁자료실

그누4 팁자료실

그누보드4와 관련된 팁을 여러분들과 함께 공유하세요.
나누면 즐거움이 커집니다.

frame에서 target=_top 사용하기 정보

frame에서 target=_top 사용하기

본문

frame 문서에서 target="_top"을 사용하고 싶을때

1. 원본 프레임문서
1-1. test1_1.php  -----  프레임 상단문서
<php
echo "<script>";
echo "window.open('test2.php','_top')";  // 프레임문서를 걷어내고 다른 페이지가 뜨게 하자
echo "</script>";
?>

1-2. test1_2.php  -----  프레임 하단문서
문서1-2

1-2. test1.php  -----  프레임문서
<html>
<head>
  <title>해피정닷컴 1</title>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<frameset rows="*, 100px" frameborder="no" border="0" framespacing="0">
  <frame name="main" noresize scrolling="auto" src="test1-1.php" marginwidth="0" marginheight="0" frameborder="no">
  <frame name="session" scrolling="no" noresize src="test1-2.php" marginwidth="0" marginheight="0" frameborder="no" />
</frameset><noframes></noframes>


2. 연결시킬 새로운 프레임문서
2-1. test2_1.php  -----  프레임2 상단문서
문서2-1

2-2. test2_2.php  ----- 프레임2 하단문서
문서2-2

2-3. test2.php  ----- 프레임2
<html>
<head>
  <title>해피정닷컴 2</title>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<frameset rows="*, 100px" frameborder="no" border="1" framespacing="0">
  <frame name="main" noresize scrolling="auto" src="test2-1.php" marginwidth="0" marginheight="0" frameborder="no">
  <frame name="session" scrolling="no" noresize src="test2-2.php" marginwidth="0" marginheight="0" frameborder="no" />
</frameset><noframes></noframes>



좋아요(추천)은 팁자료와 스킨을 만드는 힘의 원동력입니다.
추천
1

댓글 3개

요 팁의 포인트는 이렇습니다.
프레임을 사용해서 만들어진 홈페이지에서 프레임내부 문서에서 기존 프레임의 구조를 깨고
새로운 프레임문서 또는 단독문서를 열고자 사용하려는 것이구요.
전체 85 |RSS
그누4 팁자료실 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1404호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT