Problems with uploading epub files
-
Hi!
I’ve been trying to upload an epub file, but I get an error (it says it’s not possible to upload it for security reasons).
After checking with my hosting provider that it’s not a problem of upload limit, it seems I should insert a specific code line in functions.php, in Editor. I found this piece of code in the blog of someone who had the same problem, buy they were not using the Virtue Theme, so I don’t know if that would work in my case:
function addUploadMimes($mimes) {
$mimes = array_merge($mimes, array(
‘epub|mobi’ => ‘application/octet-stream’
));
return $mimes;
}
add_filter(‘upload_mimes’, ‘addUploadMimes’);Does anyone know what piece of code exactly I should insert (considering I’m using Virtue) and where? I would be so grateful!
Thanks,
Diana
- The topic ‘Problems with uploading epub files’ is closed to new replies.