add_filter('upload_dir', 'cdn_upload_url');
function cdn_upload_url($args)
{
$args['baseurl'] = 'https://your.awesomecdn.net/wp-content/uploads'; //Change to your base CDN directory - no trailing slash
return $args;
}
Forked from Fliktrax/gist:9c5f79ad038094a2684ccd14f28fe967
Last active
October 7, 2018 23:58
-
-
Save besrabasant/83e83daa556bd77da0e55564d4d1d1b7 to your computer and use it in GitHub Desktop.
WordPress >=4.7 CDN URL Update
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment