Wordpress Multisite changes download folder on sub-sites
I have a Wordpress Multisite install via GIT that has the latest commit in each environment:
- Development of
I am rewriting the main filesystem like wp-content, uploads, plugin and theme folder like this:
define( 'BLOGUPLOADDIR', $_SERVER['DOCUMENT_ROOT'] . '/media' ); define( 'UPLOADS', 'media');
Currently subsites do not use this route to handle media loading through this structure. In a local environment it works fine and the file structure goes to
. In production and development, this does not work and the files are uploaded to
The files are exactly the same, and the settings for each site are the same. I also looked in the database for each site and saw that local, dev and prod use exactly the same parameters.
I tried to look at the media upload workflow and realized that the following functions are used by defining the media upload file structure:
Looking further, I see in the next function an alternative parameter does the rewriting.
I want to know what is causing the rewrite behavior on my local machine, so I can create a solution to run this in each default environment.
source to share
No one has answered this question yet
Check out similar questions: