Skip to content

Instantly share code, notes, and snippets.

@asterion
Created October 30, 2017 14:07
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save asterion/eb5ed28b2d7b2c8022c0b1d595d98e75 to your computer and use it in GitHub Desktop.
upload svg wordpress
<?php
/* codigo ... */
function svg_mime_type($mime_types){
$mime_types['svg'] = 'image/svg+xml';
return $mime_types;
}
add_filter('upload_mimes', 'svg_mime_type', 1, 1);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment