아직 로그인하지 않았습니다. 로그인 또는 회원 등록을 해 주시기 바랍니다.

안내

글을 찾기 위한 검색 메뉴는 바로 위 메뉴의 '회원 명단' 옆에 있습니다~
TNF는 회사가 아니라 오픈소스 커뮤니티입니다. textcube.org 는 회사에서 운영하는 서비스가 아니라, 커뮤니티에서 개발하는 소프트웨어입니다.
(2007.1.10) TNF는 해당 포럼 및 위키, trac 저장소상에서 이메일 수집을 금지합니다. 해당 공지 를 포럼 하단에 명기하였습니다.
(2007.2.9) TNF와 태터툴즈/텍스트큐브 코드 수정에 관한 workflow를 정리하였습니다. 안내
(2007.4.5) 공식 소스 버그 리포터 그룹의 일원이 되어주실 분들을 찾습니다. :) 관련 공지

최근소식

(2016.1.18) 텍스트큐브 1.10.9 의 첫 베타 버전을 배포합니다. 내려받기
(2015.11.19) 텍스트큐브 1.10.8 : Tempo primo를 배포합니다. 내려받기
(2015.7.9) 텍스트큐브 1.10.8의 첫번째 발표 후보를 배포합니다. 내려받기
(2015.6.4) 텍스트큐브 1.10.7 : Tempo primo를 배포합니다. 내려받기

포럼 내용 넘어가기

TNF : Tatter Network Foundation forum

태터 네트워크 재단 - 태터앤프렌즈 포럼입니다 :)


새 댓글 쓰기

새 댓글 쓰기

새 댓글 쓰기

사용할 수 있는 기능: BBCode 이미지 웃음그림

입력을 마치기 전에 (필수) 로 명기된 부분은 모두 적어 주셔야 합니다.

방문자의 경우 필요한 정보



Captcha image. Turn pictures on to see it.
필요한 정보
선택사항설정

주제 보기 (새 글 순)

1

폐쇠형 게이트 대문 구현으로 텍스트큐브로 접속하는 세션인증제도를만들었습니다.

다름이 아니라,


rewrite.php // 소스...

<? session_start(); ?>
<?php
    define('ROOT', '.');
    /* Workaround for IIS environment */
    if(!isset($_SERVER['REQUEST_URI']) && isset($_SERVER['SCRIPT_NAME'])) {
        $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'];
        if(isset($_SERVER['QUERY_STRING']) && !empty($_SERVER['QUERY_STRING'])) $_SERVER['REQUEST_URI'] .= '?'.$_SERVER['QUERY_STRING'];
    }
    if (!empty($_SERVER['PRELOAD_CONFIG']) && file_exists('config.php')) require_once ROOT."/config.php";
        /* Retrieve Access Parameter Information. */
    $accessInfo = array(
        'host'     => $_SERVER['HTTP_HOST'],
        'fullpath' => str_replace('index.php', '', $_SERVER["REQUEST_URI"]),
        'position' => $_SERVER["SCRIPT_NAME"],
        'root'     => rtrim(str_replace('rewrite.php', '', $_SERVER["SCRIPT_NAME"]), 'index.php')
        );
    if (strpos($accessInfo['fullpath'],$accessInfo['root']) !== 0)
        $accessInfo['fullpath'] = $accessInfo['root'].substr($accessInfo['fullpath'], strlen($accessInfo['root']) - 1);
    // Workaround for compartibility with fastCGI / Other environment
    $accessInfo['input'] = ltrim(substr($accessInfo['fullpath'],
        strlen($accessInfo['root']) + (defined('__TEXTCUBE_NO_FANCY_URL__') ? 1 : 0)),'/');
    // Support Tattertools 0.9x legacy address (for upgrade users)
    if (array_key_exists('pl', $_GET) && strval(intval($_GET['pl'])) == $_GET['pl']) { header("Location: ".$accessInfo['root'].$_GET['pl']); exit;}
    $part = strtok($accessInfo['input'], '/');
    if (in_array($part, array('image','plugins','script','cache','skin','style','attach','thumbnail'))) {
        $part = ltrim(rtrim($part == 'thumbnail' ?
              preg_replace('/thumbnail/', 'cache/thumbnail', $accessInfo['input'], 1) :
              $accessInfo['input']), '/');
        if(file_exists($part)) {
            require_once ROOT.'/lib/function/file.php';
            dumpWithEtag($part);
            exit;
        } else {
            header("HTTP/1.0 404 Not Found");exit;
        }
    }
    if (strtok($part, '?') == 'setup.php') {require 'setup.php'; exit;}
    $accessInfo['URLfragment'] = explode('/',strtok($accessInfo['input'],'?'));
    unset($part);
    @session_start();
    /* Check the existence of config.php (whether installed or not) */
    if (!file_exists('config.php')) {
        if (file_exists('.htaccess')) {print "<html><body>Remove '.htaccess' file first!</body></html>";exit;}
        print "<html><body><a id='setup' href='".rtrim($_SERVER["REQUEST_URI"],"/")."/setup.php'>Click to setup.</a></body></html>";exit;
    }
    /* Determine that which interface should be loaded. */
    require_once 'config.php';
    if(defined('__TEXTCUBE_NO_FANCY_URL__')) $service['type'] = 'single';
    switch ($service['type']) {
        case 'path': // For path-based multi blog.
            array_splice($accessInfo['URLfragment'],0,1);
            $pathPart = ltrim(rtrim(strtok(strstr($accessInfo['input'],'/'), '?'), '/'), '/');
            break;
        case 'single':
            $pathPart = (strpos($accessInfo['input'],'?') !== 0 ? ltrim(rtrim(strtok($accessInfo['input'], '?'), '/'), '/') : '');
            break;
        case 'domain': default:
            $pathPart = ltrim(rtrim(strtok($accessInfo['fullpath'], '?'), '/'), '/');
            if(!empty($service['path'])) $pathPart = ltrim($pathPart,$service['path']);
            break;
    }
    $pathPart = strtok($pathPart,'&');
    /* Load interface. */
    $interfacePath = null;
    if (in_array($pathPart, array('favicon.ico','index.gif'))) {require_once 'interface/'.$pathPart.'.php';    exit;}
    if (!empty($accessInfo['URLfragment']) &&
        in_array($accessInfo['URLfragment'][0],
                 array('api','archive','attachment','author','category','checkup','cover','cron','entry','feeder','foaf','guestbook','keylog','location','logout','notice','page','plugin','pluginForOwner','search','suggest','sync','tag','ttxml')))
    {
        $pathPart = $accessInfo['URLfragment'][0];
        $interfacePath = 'interface/blog/'.$pathPart.'.php';
    } else if (is_numeric(strtok(end($accessInfo['URLfragment']), '&'))) {
        $pathPart = count($accessInfo['URLfragment'])==1 ? null : implode('/', array_slice($accessInfo['URLfragment'], 0, count($accessInfo['URLfragment']) - 1));
    }
    if (empty($interfacePath)) $interfacePath = 'interface/'.(empty($pathPart) ? '' : $pathPart.'/').'index.php';
    define('PATH', 'interface/'.(empty($pathPart) ? '' : $pathPart.'/'));
    unset($pathPart);
    if (!file_exists($interfacePath)) { require "lib/error.php";errorExit(404);}
    if (empty($service['debugmode'])) {    @include_once $interfacePath;}
    else {include_once $interfacePath;}
?>

맨윗줄에, 절대 변수 세션 <? session_start(); ?> 을 넣으니깐, 제가만든 인증세션은 작동하는데,

텍스터큐브 의 관리자 로그인이나, 메뉴 하이퍼링크를 클릭하면, 기능들이 죽어버립니다. 안된다는거죠...

<? session_start(); ?> 을 넣고싶은데, 어데다가 넣으면 좋을까요?



Currently installed 7 official extensions. Copyright © 2003–2009 PunBB.