Created
October 20, 2015 22:06
-
-
Save stevenkword/b7b1caaec6f43a06e3df to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Place this in functions.php of your theme | |
function example_mime_types($mimes) { | |
if( ! current_user_can( 'administrator' ) ) { | |
return $mimes; | |
$mimes['svg'] = 'image/svg+xml'; | |
return $mimes; | |
} | |
add_filter('upload_mimes', 'example_mime_types'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment