Skip to content

Instantly share code, notes, and snippets.

@pebriana
Created April 12, 2016 09:31
Show Gist options
  • Select an option

  • Save pebriana/fb2e2ca67ab8d4c24b4001550415d37c to your computer and use it in GitHub Desktop.

Select an option

Save pebriana/fb2e2ca67ab8d4c24b4001550415d37c to your computer and use it in GitHub Desktop.
redirect to https and remove index.php
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* index.php/$0 [PT,L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment