I have a main domain (maindomain.com) and an add-on domain (addondomain.com) hosted at the same server, both with blogs. The files for the add-on domain, which is running WordPress, are in a directory under the root of the main domain. The main domain used to have a WordPress blog, but now I use different software, so I want to redirect http://maindomain.com/feed to a FeedBurner URL. In the .htaccess in the root of the main domain, this rule
Redirect /feed/ http://feeds.feedburner.com/MyFeed
successfully redirects the feed for the main URL. The trouble is that it also redirects the feed for the add-on domain, so http://addondomain.com/feed/ also points to that FeedBurner URL.
How can I create redirects just for the main domain and not for the add-on domain?
Use mod_rewrite. It may already be enabled by default, but if not, on Linux
And then at to your .htaccess the following: