-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.htaccess
executable file
·29 lines (23 loc) · 989 Bytes
/
.htaccess
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
RewriteEngine On
RewriteRule ^sitemap.xml/?$ sitemap.php
RewriteRule ^sitemap_post.xml/?$ sitemap_post.php
RewriteRule ^sitemap_cat.xml/?$ sitemap_cat.php
RewriteRule ^sitemap_for_google.xml/?$ sitemap_for_google.php
# RSS Feed
RewriteRule ^rss.xml/?$ rss.php
RewriteRule ^rss_for_google.xml/?$ rss_for_google.php
#RewriteBase /demo/
#RewriteCond %{REQUEST_FILENAME} !-f [NC]
#RewriteCond %{REQUEST_FILENAME} !-d [NC]
#RewriteRule ^(.*)$ post.php?post=$1 [QSA,L]
#Rediractor Using HTACCESS
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} (.+)/$
RewriteRule ^ %1 [L,R=301]
#Remove .php ext
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php
RewriteRule ^category/([a-zA-Z0-9-/]+) category.php?cat_name=$1
RewriteRule ^post/([a-zA-Z0-9-/]+) post.php?post=$1
RewriteRule ^category_sm/([a-zA-Z0-9-/]+) category_sm.php?item=$1