Basis
This commit is contained in:
+8
-13
@@ -12,24 +12,19 @@ RewriteBase /phpCourse/exam
|
||||
RewriteRule ^phpCourse/exam/config/.* index.php [L,NC]
|
||||
RewriteRule ^phpCourse/exam/vendor/.* index.php [L,NC]
|
||||
RewriteRule ^phpCourse/exam/routes/.* index.php [L,NC]
|
||||
RewriteRule ^phpCourse/exam/react/.* index.php [L,NC]
|
||||
|
||||
##
|
||||
## White listed folders
|
||||
## API routes
|
||||
##
|
||||
RewriteCond %{REQUEST_FILENAME} -f
|
||||
RewriteCond %{REQUEST_FILENAME} !/api/docs/.*
|
||||
RewriteCond %{REQUEST_FILENAME} !/pages/.*
|
||||
RewriteRule !^index.php index.php [L,NC]
|
||||
|
||||
##
|
||||
## Block all PHP files, except index
|
||||
##
|
||||
RewriteCond %{REQUEST_FILENAME} -f
|
||||
RewriteCond %{REQUEST_FILENAME} \.php$
|
||||
RewriteRule !^index.php index.php [L,NC]
|
||||
RewriteCond %{REQUEST_FILENAME} /api/.*
|
||||
RewriteCond %{REQUEST_FILENAME} !/api/docs
|
||||
RewriteRule ^ api/index.php [L,NC,QSA]
|
||||
|
||||
##
|
||||
## Standard routes
|
||||
##
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule ^ index.php [L]
|
||||
RewriteCond %{REQUEST_FILENAME} !/api/docs
|
||||
RewriteCond %{REQUEST_FILENAME} !/dist
|
||||
RewriteRule ^ dist [L,NC,QSA]
|
||||
Reference in New Issue
Block a user