Htaccess File

freayd/a-local-shortener/master/.htaccess

REQUEST_FILENAME
# Shortening service
<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule ^([a-z0-9]{4})$ /shortener.php [L]
</IfModule>
<FilesMatch "^shortener-(config.json|random.rb)(.bak.*)?$">
  Order Allow,Deny
  Deny from all
</FilesMatch>

# Test
<IfModule mod_rewrite.c>
    RewriteBase /
    RewriteRule ^index.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
</IfModule>
Exit mobile version