So I'm trying to write a mod_rewrite rule that will send everything on my main domain to a subdomain.
For example, redirect
Here's what I have so far:
RewriteEngine On RewriteCond ^http://www\.example.com\/ [NC] RewriteRule ^(.*)$ http://sub.example.com/$1 [R=301,L]
But it doesn't seem to working. Any tips?