• I survived the upgrade to WordPress 2.0 without much trouble. Now I want to change my permalinks structure in order to be able to update old posts and make them fresh without changing their permalinks.

    I’m considering changing my permalinks structure from /%year%/%monthnum%/%postname%/ to /%post_id%/%postname%/ or /%postname%/%post_id%/. I tested /%post_id%/%postname%/ for a few minutes on my site, https://www.fatpitchfinancials.com, and it seemed to work well.

    I thought you might be able to help me with some htaccess rules for redirecting my WordPress post links after I change my permalinks from /%year%/%monthnum%/%postname%/ to /%post_id$/%postname%/. I would like to keep links on other sites to my content working by 301 redirecting links to my old date and postname urls to the new post_id postname ones. Is this possible? I tried searching the forums here for a solution, but I didn’t find one for my situation.

    Thanks.

Viewing 7 replies - 1 through 7 (of 7 total)
  • I just started a new blog and had originally setup the permalinks to be just like all of my other blogs…


    /%year%/%monthnum%/%postname%/

    Now I just changed them to

    /%category%/%postname%/

    All I did was change it in my Options/Permalinks, then hit the permalinks button, then go to my browser and empty the cache files. It seemed to be all that I had to do for my site.. https://The-Singers.com

    HART

    Sorry – I spoke too soon … It seemed to be working (I think it was working?) but then I just activated my Evermore plugin. Now it doesn’t work. What doesn’t work is when you click on the title / permalink of the post, you now get the 404 error message too. I tried deactivating the plugin and it made no difference. I also deleted the .htaccess, given permission again and recreated thru wordpress and it made no difference.

    Currently, this is my .htaccess file …

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{QUERY_STRING} ^feed=(feed|rdf|rss|rss2|atom)$
    RewriteRule ^(.*)$ https://feeds.feedburner.com/The-singerscom? [R]

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php
    </IfModule>

    # END WordPress

    Does that seem low in content to anybody? my files in other 1.5.2 blogs have more information.

    This is for this blog => https://The-Singers.com

    ut-oh .. NOT GOOD .. I tried to just put back the permalink structure to its original (thinking that would work and just void what I did) – but that did not work.

    https://the-singers.com

    In the last 22 hours since I’ve been watching the “permalinks” tag in here, there has been only problems and questions, and no answers or solutions.

    I tried replacing (can’t remember URL) the functions-post.php and classes.php and that didn’t restore.

    I tried rebooting, clearing the cache, different permalink options etc etc in the Options of wp2.0 blog .. still nothing.

    I guess I wait and hope someone figures this out… Good Luck! I’m Here waiting for you too!

    Thread Starter fatpitch

    (@fatpitch)

    I found a solution to my problem! Here is what my .htaccess looks like now:


    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/([^/]+)/?$ /?name=$4 [R=301,L]
    </IfModule>
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php
    </IfModule>

    # END WordPress

    I then installed the Permalink Redirect v 0.4.2 plugin and activated it. You can get it at https://fucoder.com/code/permalink-redirect/.

    Now both https://www.fatpitchfinancials.com/2006/01/04/new-contributors-corner-access-terms/ and https://www.fatpitchfinancials.com/200/new-contributors-corner-access-terms/ go to the same post. https://www.fatpitchfinancials.com/2006/01/04/new-contributors-corner-access-terms/ is 301 (permanently) redirected to the new link. Scott at FuCoder help me get to this solution.

    By the way, I’m running WordPress 2.0.

    That didn’t work at all. I was left to going back and seeing what others have tried …

    I even tried the “ApacheLucky13” found through codex..
    https://isaacschlueter.com/plugins/i-made/lucky-13-rewrite/

    I left a message on that page, but it’s still in moderation … maybe someone else can help me. Now – I can’t even access my site..

    On January 5th, 2006 at 19:26:44, HART Said:
    Your comment is awaiting moderation.

    Hi. and Help. I tried your plugin meaning installed and activated. I received 500 server error. I was unable to load my site. I deleted your plugin from the /folder/ without being able to deactivate. I’ve been trying to get proper permissions to my …/www/.. and htaccess files but can’t seem to do it with my WS_FTP program.

    Can you offer suggestions? According to directory
    /www = lrwxrwxrwx
    wp-htaccess.php = -rw-rw-rw-
    .htaccess = -rw-r–r–

    Everything I do doesn’t seem to change those read/write/execute. My Chmod is that Owner/Group/Other with each having read/write/execute

    I was having problem with my permalinks after I changed it to use /%category%/%postname%/ instead of dates. I guess 404 error was better than no access in hindsight .. :/ (j/k)

    https://The-Singers.com

    whew! My site is now ‘there’ … I sent a request to my host and they reset the permissions on their end. I tried and couldn’t do it – i think it’s time for a new FTP program! … Anyway, may as well post their reply for prosperity here:

    Your site is now working fine.

    If you are experiencing PHP difficluties, it may be due to permissions. Please set all permissions to 755 and remove all php flags (php variables) from the .htaccess file

    So – I’m still at Square One, after taking two steps backward .. my permalinks don’t work.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Changing Permalinks – Need Redirect Help’ is closed to new replies.