I write a lot of RewriteRule in my .htaccess file , but problem occurs when I switch from https to http pages; it
.htaccess
you can solve this by creating the domain alias
You can't do it within .htaccess, but within a http.conf section you can use the ServerName and ServerAlias directives to accomplish this.
http.conf