Make WordPress Core

Opened 8 years ago

Last modified 6 years ago

#40140 new feature request

upload_url_path doesn't seem to make any effect

Reported by: avibrazil's profile avibrazil Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.7.3
Component: Media Keywords:
Focuses: multisite Cc:

Description

An site of mine had http://site.com/articlefiles/ as the place to receive uploads, equally it was /site/root/articlefiles on the filesystem, instead of /site/root/wp-content/uploads.

Now I migrated the site into a multisite installation as site 2 and uploads are going into /site/root/articlefiles/site/2/ and all previous uploads in old posts are linked as http://site.com/articlefiles/site/2/something.jpg, causing broken images and links cause they originally don't have the "site/2" part. Editing the post, these links and images do not have the "site/2" part either. WordPress is rewriting the URL dynamically when reading the posts.

I want to keep compatibility with http://site.com/articlefiles/ and /site/root/articlefiles without the "site/2" part. I was expecting upload_url_path on options table to be the solution but it doesn't work. I put there http://site.com/articlefiles/.

How can I keep URL and path compatibility when migrating a single site to a non-primary site of multi site installation ?

Thank you in advance

Change History (2)

#1 @SergeyBiryukov
8 years ago

  • Focuses multisite added

This ticket was mentioned in Slack in #core-media by antpb. View the logs.


6 years ago

Note: See TracTickets for help on using tickets.