Skip to content

Instantly share code, notes, and snippets.

@Lalmi-Issam
Last active January 24, 2021 20:50
Show Gist options
  • Save Lalmi-Issam/e2ea64add72aabc91969e06d6c779f42 to your computer and use it in GitHub Desktop.
Save Lalmi-Issam/e2ea64add72aabc91969e06d6c779f42 to your computer and use it in GitHub Desktop.
<VirtualHost *:80>
ServerName www.arab-drama.me
ServerAlias arab-drama.me
#DocumentRoot /var/www/project
RewriteEngine on
RewriteCond %{SERVER_NAME} =arab-drama.me [OR]
RewriteCond %{SERVER_NAME} =www.arab-drama.me
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
# redirect from www.arab-movies.com to arab-movies.com
RewriteCond %{HTTP_HOST} ^www\.arab-drama\.me
RewriteRule ^(.*)$ https://arab-drama.me$1 [R=301,L]
# REDIRECT FROM IP TO DOMAIN
RewriteCond %{HTTP_HOST} ^164\.68\.102\.20$
RewriteRule .* https://arab-drama.me [R,L]
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.nicescroll/3.7.6/jquery.nicescroll.min.js"></script>
</VirtualHost>
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment