CI 묻고 답하기

제목 ci framework 책으로 공부 중입니다.
글쓴이 문군 작성시각 2015/07/19 04:45:42
댓글 : 4 추천 : 0 스크랩 : 0 조회수 : 13776   RSS
책 내용 대로 했는데
http://123.142.52.91/todo/
이것으로는 되고

이것으로는 안되는 이유가 뭘까요?
http://123.142.52.91/todo/index.php/main/lists

 
 다음글 getElementById()가 먹히질 않습니다 (8)
 이전글 또 질문입니다. 페이지네이션 ㅠㅠ (7)

댓글

ci개밟자 / 2015/07/19 20:16:16 / 추천 0
리라이트룰이 적용되서 그럴거에요. 위에가 더좋아요
변종원(웅파) / 2015/07/20 10:46:18 / 추천 0
아래 링크도 잘 나오는데요?

질문 올리시고 작업을 하셨나요?
문군 / 2015/07/21 18:43:31 / 추천 0

네,  변종원(웅파) 님. 

물론 안되는 것 확인하고 했죠. 여러가지로 설정이 안맞는 것들이 많아서 질문 올리고 계속 시도 하다보니 되더라구요. 물론 한 3일전까지 하다가 안되서 글을 올린거긴 하지만 질문 올리고 가만히 있을 수 없어서 하다보니 되더군요. 근데 설정이 조금 이상해서 이것만 좀 봐주 시겠어요?

nginx.conf 설정 (windows)

    server {
        listen       80;
        server_name  localhost;

        #charset koi8-r;

        #access_log  logs/host.access.log  main;

       
        location / {
            root   html;
            index  index.html index.htm index.php;
        # 예외 디렉토리 /js, /img, /css
           if ($request_uri ~* ^/js)
            {
            rewrite ^/todo/include/js/(.*)$ /js/$1 last;
            break;
            }

           if ($request_uri ~* ^/css)
            {
            rewrite ^/todo/include/js/(.*)$ /css/$1 last;
            break;
            }

            if ($request_uri ~* ^/img)
            {
            rewrite ^/todo/include/img/(.*)$ /img/$1 last;
            break;
            }

        #todo application
            if ($request_uri ~* ^/todo)
            {
            rewrite ^/(.*)$ /todo/index.php?/$1 last;
            break;
            }

        # remove access to system folder, also allows a 'System.php' controller
            if ($request_uri ~* ^/system)
            {
            rewrite ^/(.*)$ /index.php?/$1 last;
            break;
            }


        }

        #error_page  404              /404.html;

        # redirect server error pages to the static page /50x.html
        #
        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   html;
            try_files $uri $uri/ /index.php;
    }

        # proxy the PHP scripts to Apache listening on 127.0.0.1:80
        #
        #location ~ \.php$ {
        #    proxy_pass   http://127.0.0.1;
        #}

        # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
        #
        location ~ \.php$ {
            root           html;
            fastcgi_pass   127.0.0.1:9000;
            fastcgi_index  index.php;
        fastcgi_param SCRIPT_FILENAME  C:\MTB_Setup\Server\nginx-1.9.2\html$fastcgi_script_name;
            include        fastcgi_params;
        }




        # deny access to .htaccess files, if Apache's document root
        # concurs with nginx's one
        #
        #location ~ /\.ht {
        #    deny  all;
        #}
    }



...

문군 / 2015/07/21 18:47:26 / 추천 0
이질문을 드리는건 todo 이하의 css, js include 되어 있는 파일을 불러 오지 못하게 막는 듯한 느낌이 들어 todo 이하 루트에 저장하니 include가 되더라구요. 제가 뭘 잘못 설정한건지를 모르겠네요.