WordPress.org

Make WordPress Core

Opened 3 years ago

Last modified 3 years ago

#41006 new defect (bug)

Upon update from 4.75 to 4.8 Redirects failed.

Reported by: georgiel Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.8
Component: Administration Keywords: reporter-feedback close
Focuses: administration, template Cc:

Description

I've just had to restore a site from a backup because wordpress is ignoring the redirects set (wordpress install in subdirectory using https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory#Method_I_.28Without_URL_change.29.)

This happened after I allowed WordPress to auto-update.

After resetting the .htaccess to that recommended here, the site still was having issue as it was requesting /css/ /javascript/ and other resources from the root folder rather than the subdirectory and ignoring the redirect.

There have been no changes to the site between Thursday and the update.

Change History (5)

#1 follow-up: @georgiel
3 years ago

  • Severity changed from normal to critical

I resolved this specifically by:

  1. moving the wordpress site back to the root directory from the subdirectory
  2. running the site and logging in.
  3. Move site back to own subdirectory
  4. reset the htaccess to that which is recommended in the above link.

Updates shouldn't be able to break that though, it should be designed better.

A colossal amount of time was wasted in restoring the site.

#2 @dd32
3 years ago

  • Keywords reporter-feedback close added
  • Severity changed from critical to normal

Hi @georgiel and welcome to Trac.

Can you please provide some more details about how your install is configured, as the configuration as presented as far as I can tell works fine, there were also no changes between 4.7 and 4.8 related to this as far as I'm aware.

Things that will be of use to us include things like how you've specified the url changes, through the settings/options? If so, what do they currently read as?
What did you experience after the upgrade - was the .htaccess file the same before and after? - what is the content of it too, is it standard, or custom?
Did you perform any debugging steps in an attempt to fix or diagnose the site before the restore?

It's also a little confusing here, as you're referring to redirects which shouldn't be used in this scenario at all - there should be nothing to redirect, WordPress is simply told that the files exist in a different location.

I use the WordPress-in-a-subdirectory format on https://dd32.id.au/ without issue (I'll note that I'm also using a custom WP_CONTENT_DIR & WordPress 4.9 which is mostly the same as 4.8 currently), the only times I've ever seen something like what you're referring to is when WordPress is configured "Backwards" (Home url set to what should be the site url, and vice versa) - but that shouldn't have broken after an upgrade, it should've always been broken.

#3 follow-up: @dkurth
3 years ago

  • Severity changed from normal to critical

I can confirm this problem. My paid-for subscription site is now WIDE OPEN because of the wp_redirect() that no longer works.

#4 in reply to: ↑ 1 @dkurth
3 years ago

Replying to georgiel:

I resolved this specifically by:

  1. moving the wordpress site back to the root directory from the subdirectory
  2. running the site and logging in.
  3. Move site back to own subdirectory
  4. reset the htaccess to that which is recommended in the above link.

Updates shouldn't be able to break that though, it should be designed better.

A colossal amount of time was wasted in restoring the site.

I am in the exact same position.

#5 in reply to: ↑ 3 @dd32
3 years ago

  • Severity changed from critical to normal

Replying to dkurth:

I can confirm this problem. My paid-for subscription site is now WIDE OPEN because of the wp_redirect() that no longer works.

Your ticket #41036 sounds very different to this one, and quite possibly completely unrelated.

Note: See TracTickets for help on using tickets.