• I’ve recently ported a custom blog over to WordPress 2.0.2. Everything works great and so forth, the only problem I’ve got at the moment is my inability to come up with the correct mod_rewrite rules or a hack that would be able to redirect old URLs to their new locations.

    An old URL looks something like this:?mod=viewblog&id=123
    Since I was able to keep post id‘s the same, all I have to change basically is that ?mod=viewblog&id= bit to ?p= attaching the id at the end.

    I’ve tried (unsuccessfully, naturally) so far to do this via mod_rewrite and more recently but adding some hacks to WP’s index.php. Currently my .htaccess only contains WP’s mod_rewrite rules.

    Any help would be appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The Redirect Old Post Slugs or a similar plug-in (try searching for post redirect/old post slug redirect plug-ins etc.). I haven’t used it, but it’s a suggestion nonetheless.

    Good luck,
    Michael.

    EDIT: If you made a php script, that took the id from the mod string and then just redirected via a location header to the good post, wouldn’t that work or have you tried that already?

    Thread Starter sn

    (@sn)

    EDIT: If you made a php script, that took the id from the mod string and then just redirected via a location header to the good post, wouldn’t that work or have you tried that already?

    I eventually did it like this, yes. It works fine, but I’m concerned that it might interfere with stats programs and or put an extra load on the server during peak traffic times. I’ll take a look at the plugin you refer to. Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘mod_rewrite, hack or whatever I’d need to get this working’ is closed to new replies.