• Resolved fallback2

    (@fallback2)


    Hello,

    I successfully changed 2 blogs’ permalinks and then redirected old posts- taking out the date to just the post name – using your directions here: https://redirection.me/support/redirect-regular-expressions/ Worked immediately and thank you so much!

    I tried it with my subdomain, and this expression doesn’t work to redirect old posts. See link below. Because it’s a subdomain, is it something to do with not a regex? Or maybe fix the source differently, make it longer?

    Thank you for any help. My main site is https://donnabarstow.com/.

    • This topic was modified 2 years, 4 months ago by fallback2.

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author John Godley

    (@johnny5)

    How did you try it with your subdomain? Do you have the plugin installed on the subdomain?

    Thread Starter fallback2

    (@fallback2)

    Thank you.
    Yes, your plugin is installed on both my domain and this subdirectory. Is that ok?

    Plugin Author John Godley

    (@johnny5)

    Thread Starter fallback2

    (@fallback2)

    Okay, I repeated what I did again.

    I changed General>Permalinks from date and name to just name.

    Then I used your Source Regex: ^/\d{4}/\d{2}/\d{2}/(.*) and target /$1 to make a new Redirect.

    Not sure what you mean.
    My domain is https://donnabarstow.com/
    My subdomain is: https://donnabarstow.com/park_blog/ I linked to that post above, with the old date in it, just to show that it was not being redirected, and has a 404.

    I had my host check on pointers today…but maybe you mean something elee?
    Any ideas on why it isn’t working?

    Plugin Author John Godley

    (@johnny5)

    https://donnabarstow.com/park_blog/ is maybe a subdirectory, but a subdomain would be something like https://subdomain.donnabarstow.com/park_blog/. Do you mean you are using multisite and /park_blog/ is another site?

    If so the plugin needs to be running in the site you want to redirect from, not the site you want to redirect to.

    Thread Starter fallback2

    (@fallback2)

    John,

    Sorry, I might have used the wrong word. I wasn’t sure, and that’s why I put both in the title here. ??

    https://donnabarstow.com/park_blog/ has a separate installation of WordPress, and all separate plugins. It has its own copy of Redirection, for example. I never learned how to do multisite… I just do everything twice.

    My problem is in this site only: I want the permalink to have only the post title, since the date is ages ago, obviously. The posts don’t have the date now. But I can’t redirect to the new permalink.

    Will regex not work, since it’s a subdirectory? Do I have to redirect each post separately? (And will the images also redirect with them?)

    Plugin Author John Godley

    (@johnny5)

    Being in a subdirectory makes no difference to whether it will work or not, however your URLs still need to match. ^/\d{4}/\d{2}/\d{2}/(.*) does not match your subdirectory, and so you will need to change it so it does – probably ^/park_blog/\d{4}/\d{2}/\d{2}/(.*)

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘To change permalinks for subdomain (subdirectory)’ is closed to new replies.