Pages
Archives
- August 2010
- July 2010
- May 2010
- March 2010
- January 2010
- December 2009
- November 2009
- October 2009
- September 2009
- August 2009
- July 2009
- June 2009
- May 2009
- April 2009
- March 2009
- February 2009
- January 2009
- December 2008
- November 2008
- October 2008
- September 2008
- July 2008
- June 2008
- May 2008
- April 2008
- March 2008
- February 2008
- January 2008
- December 2007
- November 2007
- October 2007
- September 2007
- August 2007
- July 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
Migrating WordPress
As some of you might have noticed, I have just recently moved my WordPress installation into a subdirectory of arfore.com.
There are several reasons for this, the main one being that I would like for my blog to become a component of my website rather than the blog being the entire site.
Moving the WordPress installation itself was quite simple, and there are many pages out there describing the process as well as the pitfalls of doing it incorrectly, so I won’t repeat them here.
What was less easy to find was the proper changes to put in the
.htaccessfile to ensure that any existing links would get redirected to the proper location in the moved WordPress setup.I have my permalinks configured to create a URL like follows:
http://arfore.com/blog/2008/10/12/foo-bar-baz/In order to add the subdirectory blog to the front of the URL I used the following rule in my
.htaccessfile:RewriteRule ^([0-9](.*))$ http://arfore.com/blog/$1 [R=301,L]Similarly, to redirect the categories I used the following:
RewriteRule ^category/(.*)$ http://arfore.com/blog/category/$1 [R=301,L]Now this may not be the most correct method to accomplish the goal, so if it needs correcting by all means let me know.
Related posts