We talking about Cloud
Web Hosting & Cloud Services
Celebrate the power and freedom of Open Source
with Open Source Cloud Servers starting at only £10/mo £5/mo.
Web Hosting & Cloud Services
Celebrate the power and freedom of Open Source
with Open Source Cloud Servers starting at only £10/mo £5/mo.
You may notice that any custom rewrite rules you make for specific folder paths under your site’s domain will simply produce 404 errors on your WordPress blog.
To fix this, try the following:
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_URI} !^/(abc|xxx|events/go-to-town) [NC] RewriteRule . /index.php [L] RewriteRule ^abc/$ "http://wordpress.com/" [R=301,L] RewriteRule ^xxx/$ "http://support.hostgator.com/" [R=301,L] RewriteRule ^events/go-to-town/$ "http://secure.hostgator.com/~affiliat/cgi-bin/affiliates/clickthru.cgi?id=whatever" [R=301,L] </IfModule> # END WordPress
Note: This code works for WordPress blogs hosted on their own domain (primary, addon, subdomain); however, the code must be changed to work with a blog installed in a subfolder without its own domain. To make this work with a www.mydomain.com/blog type address, you just need to tweak one line: RewriteCond %{REQUEST_URI} !^/(blog/abc|blog/xxx|blog/events/go-to-town) [NC] The rewrite rules remain the same.
</IfModule>
.Warning! Each line of code in the .htaccess file must have its own new line in the file. Do not allow a long line to break and continue on a new line or your code will have unexpected behavior. For example: RewriteRule ^events/go-to-town$ "http://secure.hostgator.com/~affiliat/cgi-bin/affiliates/clickthru.cgi?id=whatever" [R=301,L] This should all be one line.