• Resolved steveraven

    (@steveraven)


    Hi,

    Super plugin that works excellently!

    But can it redirect lots of URLs on a wildcard basis?

    For eg:

    I used to have a forum with a few links to my main website. The forum is long gone now, but Google Search Console keeps picking up on old URLS from there, that I keep having to redirect one by one.

    Is there a way to set it something like:

    http://www.website.com/forum/*/

    …so that all the old forum content gets redirected automatically?

    https://wordpress.org/plugins/redirection/

Viewing 15 replies - 1 through 15 (of 16 total)
  • Thread Starter steveraven

    (@steveraven)

    Its ok, I found out how to do it.

    Should save me tons of work putting individual redirects in!

    For anyone else that might be interested, the magic formula is:

    Source url: http://your-website/old-content-thats-404-ing/(.*)
    Target url: http://your-new-page/

    …and remember to check the ‘Regular Expression’ box.

    Thanks for sharing this — very useful to know!

    Could you help me with this one?
    I took over an old website http://www.mywebsite.nl and the posts were like:
    http://www.mywebsite.nl/tellafriend.asp?ber_id=4246

    How can I setup a redirect to only http://www.mywebsite.nl/ for ALL ?ber_ID’s in this (and other) categories?

    Thanks…

    • This reply was modified 7 years, 4 months ago by xonnext.

    Thank you steveraven! you have saved me a ton of time and fiddling. Such a simple fix!

    We needed to implement a redirect for all .PDF files to the homepage following the website being infected with the Pharma hack. This will now help us remove all the links in Google to malicious PDF documents the hack left.

    For anyone else wanting to do this we put in the following:

    301 redirect
    Source: /(.*).pdf
    Regex box: ticked
    Target: the websites full address

    How can I setup a redirect to only http://www.mywebsite.nl/ for ALL ?ber_ID’s in this (and other) categories?

    I think the following should work

    Source URL: ?ber_id=\d+
    Regex: Checked
    Target URL: /

    hi, @steveraven

    I want to redirect all error pages to the main page ?

    It was not your example.

    help me pls.

    • This reply was modified 7 years, 3 months ago by teoder.

    Look for a separate plugin for this – there are lots to choose from.

    Tip: I finaly installes the plugin ‘404 Plugin for WordPress’ by Fakhri Alsadi. And ALL my GoogleAnalytics Crawl Errors were gone. It redirects everything that does not exist (anymore).

    rcarpadus

    (@rcarpadus)

    “For anyone else that might be interested, the magic formula is:

    Source url: http://your-website/old-content-thats-404-ing/(.*)
    Target url: http://your-new-page/
    …and remember to check the ‘Regular Expression’ box.”

    I tried to redirect the wildcard “/resources/video_full/(.*)” to “/videos/entry/(.*)” but it doesn’t work. Any ideas why?

    It doesn’t seem to matter if RegEx is checked or not (Side question; what does that box do?)

    jdaviescoates

    (@jdaviescoates)

    I want to do:

    olddomain/(.*)
    to
    newdomain/(.*)

    But can’t work out how to do so…

    EastDevonAlliance

    (@eastdevonalliance)

    Source url: http://olddomain/(.*)
    Target url: http://newdomain/$1
    jdaviescoates

    (@jdaviescoates)

    Thanks, but nope, that didn’t seem to work :-/

    EastDevonAlliance

    (@eastdevonalliance)

    Did you set regex?

    Otherwise you can hand craft a .htaccess rule.

    I have a bunch of 404s that are happening because of old plugins that I’ve uninstalled so the path is https://mysite.com/​wp-content​/plugins​/someplugin/etc. Is there a way for me to redirect all of those 404s to the home page with one redirect via wildcard?

    I mean, there’s no reason for them to not go there anyway if they are headed to the plugin directory. Same thing for things like readme.html and images that no longer exist.

    This thread would, from what I understand, seem to be the closest related to the question I have.
    Please pardon my ignorance, it’s been 8+ years since I used any WP, and kind of crash-coursing over the last several weeks in a desperate attempt to get away from Squarespace.

    When I made the SqrSpc site, I had in the aforementioned ignorance, made a URL structure that I decided to not follow exactly when I made the move and imported all previous posts to the new site.

    Simply, my question is this; I want to create a redirect for all past articles (which are stil linked in older social media posts, etc) based on the removal of one part of the URL. Example:

    old url: http://www.site.com/word/year/month/day/title

    new urls: http://www.site.com/year/month/day/title

    Can this be done with wildcards? Or will this be an “add a redirect for 400+ articles” project?

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Wildcard Redirects?’ is closed to new replies.