세션 변수를 이용한 index.php를 사이트 대문 만들기

· 2008-06-13 (금) 22:56:18 · 5373
common.php에서

@session_start();
if( $start_on) set_session("start_on_index", 'on');
if( $_SESSION['start_on_index'] != 'on') alert('xxxxxx', $g4['path'] );


이렇게 두 줄 추가.


$g4['path'](대부분이 index.php)에서는

<?php
$start_on='on;
include '_common.php';

common.php 이전에 start_on 변수 설정

모든 파일은 common.php를 include할 것


참조: http://sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=15023&sca=&sfl=wr_subject%7C%7Cwr_content&stx=gate&sop=and
|
댓글을 작성하시려면 로그인이 필요합니다.

그누4 팁자료실

3,309건

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

+
제목 글쓴이 날짜 조회
08-06-18 조회 1.2만
08-06-14 조회 2,747
08-06-13 조회 5,374
08-06-13 조회 5,066
08-06-13 조회 3,927
08-06-12 조회 2,805
08-06-12 조회 3,247
08-06-12 조회 6,520
08-06-11 조회 2,849
08-06-11 조회 3,189
08-06-11 조회 4,967
08-06-11 조회 2,577
08-06-11 조회 4,621
08-06-10 조회 3,480
08-06-10 조회 6,683
08-06-07 조회 4,336
08-06-06 조회 3,397
08-06-04 조회 3,354
08-06-04 조회 3,317
08-06-03 조회 3,862