Created
October 23, 2018 13:19
-
-
Save gregoriopellegrino/895add2f01746733c5da2a5969079470 to your computer and use it in GitHub Desktop.
wordpress-epub-allowed-filetypes
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
// This snippet adds epub mime-type to WordPress' allowed mime-types, so you can upload epub files to WP | |
// add this to your theme's function.php file | |
add_filter('upload_mimes', 'eme_myme_types', 1, 1); | |
function eme_myme_types($mime_types){ | |
$mime_types['epub'] = 'application/epub+zip'; | |
return $mime_types; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment