profis/profiscms/master/.htaccess - Htaccess File

profis/profiscms/master/.htaccess

Options All -Indexes
<IfModule mod_php.c>
  php_flag register_globals off
  php_flag display_errors on
</IfModule>
<IfModule mod_php5.c>
  php_flag register_globals off
  php_flag display_errors on
</IfModule>
RewriteEngine on

RewriteCond %{REQUEST_URI} ^/admin$
RewriteRule ^(.*)$ /admin/ [R=301,L]

# sitemap.xml
RewriteCond %{REQUEST_URI} sitemap.xml
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ api/ [QSA,L]

# robots
#RewriteCond %{REQUEST_URI} ^.*/robots.txt/
#RewriteRule ^(.*)/$ /$1 [R=301,L]

# gallery
#RewriteCond %{REQUEST_URI} new/gallery/(.*)
#RewriteRule ^(.*)new/gallery/(.*) $1gallery/$2 [L,R=301]

# api
RewriteCond %{REQUEST_URI} admin/api/(.*)
RewriteRule ^(.+)$ core/api/admin/$1 [QSA]
RewriteCond %{REQUEST_URI} (ww)/api/(.*)
RewriteRule ^(.+)$ api/$1/$2 [QSA]
RewriteCond %{REQUEST_URI} api/(.*)
RewriteRule ^(.+)$ core/api.php?$1 [QSA,L]

# public page
RewriteCond %{REQUEST_URI} !admin/(.*)
RewriteCond %{REQUEST_FILENAME} !-f
#RewriteCond %{REQUEST_FILENAME} !-d [OR]
#RewriteCond %{REQUEST_URI} /$

#Everything goes to site.php
RewriteRule ^(.*)$ site.php

<Files PC_errors.txt>
  order allow,deny
  deny from all
</Files>

On Github License

Files

Download PDF of Htaccess file
REQUEST_FILENAME, REQUEST_URI

Comments

Apache