Loading...

Category: Real Time Concepts

Rewrite Rule Reference

Rewrites Rewrite domain.com to www.domain.com RewriteEngine On RewriteCond %{HTTP_HOST} !^www [NC] RewriteRule ^(.*)$ http://www.%{HTTP_HOST}$1 [R=301,L] Rewrite www.domain.com to domain.com RewriteEngine On RewriteCond %{HTTP_HOST} ^www.domain.com [NC] RewriteRule ^(.*)$ http://domain.com$1 [L,R=301] Rewrite [ … ]

Apache

Installation RHEL / CentOS Apache can be installed via yum as shown below: [root@web01 ~]# yum install httpd httpd-tools mod_ssl When you setup Apache, its common to also setup PHP. [ … ]

Apache Mod_Rewrite

Installation mod_rewrite is a standard Apache module configured by default. Configuration To allow RewriteRules in .htaccess files, you need a minimum of AllowOverride FileInfo in the VirtualHost or Directory config. [ … ]