WordPress.org

Ready to get started?Download WordPress

Forums

301 redirect old url structure to new getting 404's (2 posts)

  1. jlinder
    Member
    Posted 2 years ago #

    I've moved a old site on another CMS to a new wordpress installation on a new domain. The url structure is completely different, some pages are combined.

    I've manually matched the old and new url's for a 301 redirect, but when I when the redirect occurs the new url has part of the old url added to the end. For example:

    Redirect 301 /ActiveListings.php/Details/96 http://domain.com/featured-listings/ ends in a 404 with the following url in the browser http://domain.com/featured-listings/Details/96

    What do I need to change to keep the end of the source url from being added to the target url? I thought I have 301'd all the pages and everything was good but I'm getting lots of 404's. Any help is appreciated.

  2. dcivinelli
    Member
    Posted 2 years ago #

    The dot in the ".php" might be throwing it off. You might have to use a regular expression to escape the dot. Try this:

    redirectMatch 301 /ActiveListings\.php/Details/96 http://domain.com/featured-listings/

    (My regular expression syntax may very well be off...)

    If that doesn't work, try reading through either of these pages for more information:
    http://www.squidoo.com/301
    http://www.askapache.com/htaccess/301-redirect-with-mod_rewrite-or-redirectmatch.html

Topic Closed

This topic has been closed to new replies.

About this Topic