Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alainlankers/f4c6006c3d6ada797dbe17e46ff23fc7 to your computer and use it in GitHub Desktop.
Save alainlankers/f4c6006c3d6ada797dbe17e46ff23fc7 to your computer and use it in GitHub Desktop.
enabling mod_rewrite
sudo a2enmod rewrite
sudo systemctl restart apache2
sudo nano /etc/apache2/sites-available/000-default.conf
add:
<VirtualHost *:80>
<Directory /var/www/html>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
. . .
</VirtualHost>
sudo apache2ctl configtest
sudo systemctl restart apache2
sudo nano /var/www/html/.htaccess
add:
RewriteEngine on
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment