CI 묻고 답하기

제목 htaccess 관련
카테고리 CI 2, 3
글쓴이 기냥이 작성시각 2017/06/10 14:36:24
댓글 : 6 추천 : 0 스크랩 : 0 조회수 : 12741   RSS

안녕하세요,

index.php가 제거되지 않아서 .htaccess 관련 질문 좀 드리고 싶습니다.

현재 제 디렉토리는,

/

/applications

 /app1

 /app2

/system

...

입니다.

 

/ 에 있는 .htaccess 내용은 아래와 같이 작성했습니다. (수정)

<IfModule mod_rewrite.c>

    RewriteEngine On

    RewriteBase /

    RewriteCond $1 !^(index\.php|images|captcha|data|assets|uploads|robots\.txt)

    RewriteCond %{REQUEST_FILENAME} !-f

    RewriteCond %{REQUEST_FILENAME} !-d

    RewriteRule ^(.*)$ /applications/app1/index.php/$1 [L]

</IfModule>

 

무엇이 문제일까요ㅠㅠ

 다음글 site_url()이 도메인이 아닌 ip주소로 출력됩니... (4)
 이전글 파일 업로드시 A PHP Error was encoun... (5)

댓글

kaido / 2017/06/10 17:48:16 / 추천 0

리라이트 모드를 활성화 하지 않으시면 .htaccess  파일이 적용되지 않습니다.

apache mod_rewrite 로 검색해 보세요

기냥이 / 2017/06/10 18:48:37 / 추천 0
아-서버설정은 다 되어있습니다. 모듈 로드되어있습니다.ㅠ
kaido / 2017/06/10 18:59:21 / 추천 0
<IfModule mod_rewrite.c>
 RewriteEngine On
 RewriteBase /
 RewriteCond $1 !^(index\.php|images|captcha|data|include|uploads|robots\.txt)
 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
 RewriteRule ^(.*)$ /index.php/$1 [L]
</IfModule>

한번 이걸로 넣어보시고... 서버 리부팅 한번 해 보세요.

변종원(웅파) / 2017/06/11 00:51:29 / 추천 0
application 하위에 app1, 2가 존재하네요. index.php의 정확한 위치는 어딘가요?
기냥이 / 2017/06/11 15:42:37 / 추천 0

index.php는 각 어플리케이션별로 넣어놨습니다.

/applications/app1/index.php, /applications/app2/index.php

기냥이 / 2017/06/11 16:45:13 / 추천 0

해결됐습니다...허무하게 ;;;

익스플로러 임시파일 삭제하니까 제대로 돌아가네요....ㅠㅠ

처음 질문에 적었던 htaccess파일 내용이 맞았습니다.

모두 답변 감사합니다~~