GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   .htaccess Wordpress Migration Help (https://gfy.com/showthread.php?t=996151)

The Dawg 11-05-2010 09:22 AM

.htaccess Wordpress Migration Help
 
Hello All -

I am moving one of my blogs to WP and I want to use a new type of URL structure.

The old blog has URLs like this: domain.com/blog/?itemid=1021

WP has URLs like this: domain.com/blog/2011-audi-r8-spyder/

*Those two URLs point to the same entry.

How can I use Condition/Rewrite Rules to redirect to the new permanent URLs?

myneid 11-05-2010 09:43 AM

if you migrated from an old blog system to wordpress and want the old links to still work,
it will be a bit difficult
you would need to redirect the old link so anything that ended in ?itemid=xxxx to a php or whatever program that would need to know which old blog entry relates to the new wordpress entry

The Dawg 11-05-2010 09:47 AM

Quote:

Originally Posted by myneid (Post 17675126)
if you migrated from an old blog system to wordpress and want the old links to still work,
it will be a bit difficult
you would need to redirect the old link so anything that ended in ?itemid=xxxx to a php or whatever program that would need to know which old blog entry relates to the new wordpress entry

Thanks Ive done it in the past redirecting old html pages to new pages within a script, but since WP has its own .htaccess to make the custom URLs I dont know how to edit it.

Even if I have to put a line for every post I'd do it.

Hentaikid 11-06-2010 07:51 AM

Actually wordpress shortlinks are numeric too... so you have domain.com/?p=1021 as a valid alternate url for that post (It's under show shortlink in the post form) so if you migrate and keep the numeric values for the posts it should redirect them... possibly. I know with nice urls if the url is wrong it will try to send you to the closest titled post...


All times are GMT -7. The time now is 09:40 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc