Skip to main content

In order to change the default media upload location, you need to edit the wp-config.php file located in the root directory of your WordPress installation. If you want upload directory to be wp-content/files then you will need to place the following code in wp-config.php

define( 'UPLOADS', 'wp-content/'.'files' );wp-config.php

define( 'UPLOADS', 'wp-content/'.'files' );

If you want the upload directory to be outside wp-content, like http://www.example.com/files/http://www.example.com/files/ then you need to set upload path in wp-config.phpwp-config.php like this:

define( 'UPLOADS', ''.'files' );

define( 'UPLOADS', ''.'files' );

Remember you can still choose whether or not you want uploaded files to be organized in month/year folders in Settings » MediaSettings » Media.

Function Reference /wp_upload_dir – WordPress Codex

In order to change the default media upload location, you need to edit the wp-config.php file located in the root directory of your WordPress installation. If you want upload directory to be wp-content/files then you will need to place the following code in wp-config.php

define( 'UPLOADS', 'wp-content/'.'files' );

If you want the upload directory to be outside wp-content, like http://www.example.com/files/ then you need to set upload path in wp-config.php like this:

define( 'UPLOADS', ''.'files' );

Remember you can still choose whether or not you want uploaded files to be organized in month/year folders in Settings » Media.

Function Reference /wp_upload_dir – WordPress Codex

In order to change the default media upload location, you need to edit the wp-config.php file located in the root directory of your WordPress installation. If you want upload directory to be wp-content/files then you will need to place the following code in wp-config.php

define( 'UPLOADS', 'wp-content/'.'files' );

If you want the upload directory to be outside wp-content, like http://www.example.com/files/ then you need to set upload path in wp-config.php like this:

define( 'UPLOADS', ''.'files' );

Remember you can still choose whether or not you want uploaded files to be organized in month/year folders in Settings » Media.

Function Reference /wp_upload_dir – WordPress Codex

Source Link

In order to change the default media upload location, you need to edit the wp-config.php file located in the root directory of your WordPress installation. If you want upload directory to be wp-content/files then you will need to place the following code in wp-config.php

define( 'UPLOADS', 'wp-content/'.'files' );

If you want the upload directory to be outside wp-content, like http://www.example.com/files/ then you need to set upload path in wp-config.php like this:

define( 'UPLOADS', ''.'files' );

Remember you can still choose whether or not you want uploaded files to be organized in month/year folders in Settings » Media.

Function Reference /wp_upload_dir – WordPress Codex