I moved an ex-site according to joomla to wordpress. Import labored fine but however , that old links aren't effective any longer. Because there's only 50 approximately articles, i figured is going to be smart to put a guide for every publish (inshtaccess).

Well... Not necessarily situations are as if you want, so redirects dont work on all :(

Old joomla links appears like this:

http://site.com/index.php?option=com_content&task=view&id=49&Itemid=29
http://site.com/index.php?option=com_content&task=view&id=42&Itemid=29
http://site.com/index.php?option=com_content&task=view&id=68&Itemid=29

And have to be converted to:

http://site.com/?p=23
http://site.com/?p=24
http://site.com/?p=25
  • essentially no relations between old and new links, and so i don't believe a regex can help

  • both old and new site are on a single domain

Ok, however , any rule i have attempted (and that i attempted a great deal!), none labored. in couple of cases i recieve 500 error, but many of occasions the redirect did not work.

So, any one of everyone had same issue? I do not necessary wish to have nice permalinks, but when i'm able to, that'll be better. However , i've many back links to old url's and i'd rather not loose them.

Thanks men!

Because the conversion of the site to Wordpress is comparatively new, can there be anything stopping you against while using old Joomla! ID's inside your Wordpress database table? This could permit you to make use of a regex fairly easily.

Another option is to produce a separate PHP script that handles the Joomla! Web addresses then redirects towards the Wordpress ones. Which means you might have a regex inside your Apache configuration discovering index.php?option=com_content&task=view Web addresses, locating the value for 'id', then redirecting to someotherscript.php that will possess a map of the ids from Joomla! to Wordpress. This script would then use header('Location: ?p=' . $id) to redirect towards the correct page in Wordpress.

Thnaks for that idea! I put this in index.php (wordpres default):

if(isset($_GET['option'])) {
    if(is_numeric($_GET['id'])){
    	header ('HTTP/1.1 301 Moved Permanently');
    	header("Location: http://www.site.com/?p={$_GET['id']}");
    	die();
    }else {
    	die('Hacking attempt');
    }
}

And works like... GREAT! :D

An alternative choice may have been to utilize a redirection wordpress plugin to get this done for you personally. Saves the answer breaking every time you change or improve your theme.