RewriteEngine on
# hide files and folders
RedirectMatch 404 /_protected
RedirectMatch 404 /.git
RedirectMatch 404 /composer.
RedirectMatch 404 /.bowerrc
# Turn on URL rewriting only when mod rewrite is turn on
<IfModule mod_rewrite.c>
# If a directory or a file exists, use the request directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# Otherwise forward the request to index.php
RewriteRule . index.php
</IfModule>
# Protect the htaccess from being viewed
<Files .htaccess>
order allow,deny
deny from all
</Files>
# Don't show directory listings for URLs which map to a directory.
Options -Indexes
#Follow symlinks
Options +FollowSymlinks