Wordpress - Change WordPress upload path and URL

I went to the wp-admin/options.php page and set ... But is that how it's supposed to be done?

Nope. You should never change anything in the WordPress core files because all your changes will be lost during the next update. You should use actions and filters instead:

add_filter( 'pre_option_upload_path', function( $upload_path ) {
    return '/path/to/static';
});

add_filter( 'pre_option_upload_url_path', function( $upload_url_path ) {
    return 'http://static.example.org';
});

Tags:

Uploads