채택완료

htaccess 질문드리겠습니다!

2021-07-11 (일) 13:57:57 1,780

https://도메인주소/funny/funny.php 로 들어가야뜨는걸 https://도메인주소/funny 로 바꾸고싶은데

밑에처럼 작성하여 쓰면될까요?

#### 그누보드5 rewrite BEGIN #####
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^content/([0-9a-zA-Z_]+)$  bbs/content.php?co_id=$1&rewrite=1  [QSA,L]
RewriteRule ^content/([^/]+)/$  bbs/content.php?co_seo_title=$1&rewrite=1      [QSA,L]
RewriteRule ^rss/([0-9a-zA-Z_]+)$  bbs/rss.php?bo_table=$1        [QSA,L]
RewriteRule ^([0-9a-zA-Z_]+)$  bbs/board.php?bo_table=$1&rewrite=1      [QSA,L]
RewriteRule ^([0-9a-zA-Z_]+)/([^/]+)/$ bbs/board.php?bo_table=$1&wr_seo_title=$2&rewrite=1      [QSA,L]
RewriteRule ^([0-9a-zA-Z_]+)/write$  bbs/write.php?bo_table=$1&rewrite=1    [QSA,L]
RewriteRule ^([0-9a-zA-Z_]+)/([0-9]+)$  bbs/board.php?bo_table=$1&wr_id=$2&rewrite=1  [QSA,L]
RewriteRule ^funny/(.*) /funny/funny.php [QSA,L]
</IfModule>
#### 그누보드5 rewrite END #####

|

답변 1개 / 댓글 4개

채택된 답변
+20 포인트
2021-07-11 (일) 14:58:57

https://도메인주소/funny/funny.php

funny.php를

index.php로 바꾸시면 될 듯합니다.

답변에 대한 댓글 4개

그럼 RewriteRule ^funny/(.*) /funny/funny.php [QSA,L] 이부분은 어떻게 수정해야할까요?
그냥 RewriteRule ^funny/(.*) /funny/funny.php [QSA,L] 이거 추가할필요없이 index.php 로 바꾸면 자동으로 될까요?
굳이 rewriet 쓸 필요가 없습니다.
감사합니다!

답변을 작성하려면 로그인이 필요합니다.