views:

42

answers:

2

This is a really weird question and I apologize:

I've been asked if it's possible not to import our blog from Wordpress to Drupal but just keep it in Wordpress as an archive and re-direct our users say from hostname/blog/... to hostname/wordpress/... when a URL matches the Wordpress URL pattern.

I've never heard of anyone trying this and I'm wondering about pitfalls and whether or not it's even possible.

Thanks!

D

+1  A: 

This looks like it should be pretty simple to do. I plan to take advantage of the mod_rewrite module for apache:

We will just need to configure a .htaccess file to redirect URLs matching hostname/blog/pattern/ - where pattern fits a Wordpress URL blog pattern.

DKinzer
+1  A: 

I use mod_rewrite on my Drupal site. Here's an example I use to redirect users to www.earldouglas.com when they access earldouglas.com:

RewriteCond %{HTTP_HOST} ^earldouglas.com [NC]
RewriteRule ^(.*)$ http://www.earldouglas.com/$1 [L,R=301]

You could try something like the following:

RewriteCond %{REQUEST_URI} /blog
RewriteRule ^(.*)$ /wordpress [L,QSA]
James Earl Douglas
Yeah, we did end up doing something very similar to this.
DKinzer