Page Title
Body Apache's rewrite rules allow you to change an incoming request for different reasons- perhaps because a page moved or your site layout changed. Here are some examples of how you can use rewrite rules in your site. After you make any changes to your apache configuration, be sure to restart apache. On CentOS, you do this with <pre><code> sudo /sbin/service httpd restart </code></pre> h3. HTTP_HOST Rewriting For various reasons you may want to redirect all of your traffic to a single subdomain. For example, you "might want to":http://no-www.org send all traffic for www.mydomain.com to mydomain.com. To do that, add this to your apache configuration. You'll usually want to put it inside the <code>VirtualHost</code> context. <pre><code> RewriteEngine On # You might already have this line RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC] RewriteRule ^(.*)$ http://%1/$1 [R=301,L] </code></pre>
Make page private