A couple of notes – if I try a 29mb flac it fails with ‘0’
if I try a smaller flac – it returns on screen error:
There was an error with your submission
This kind of file is not allowed. Please, try again selecting other file.:
Top-Gun.flac
so I updated to:
/* MIME Types */
add_filter( 'fu_allowed_mime_types', 'my_fu_allowed_mime_types' );
function my_fu_allowed_mime_types( $mime_types ) {
// Array keys should be unique
// To include all mime-types we use this workaround
// Part after | could be anything as long as it's unique
$mp3_mimes = array( 'audio/mpeg', 'audio/x-mpeg', 'audio/mp3', 'audio/x-mp3', 'audio/mpeg3', 'audio/x-mpeg3', 'audio/mpg', 'audio/x-mpg', 'audio/x-mpegaudio' );
foreach( $mp3_mimes as $mp3_mime ) {
$mime = $mp3_mime;
preg_replace("/[^0-9a-zA-Z ]/", "", $mp3_mime );
$mime_types['mp3|mp3_' . $mp3_mime ] = $mime;
}
$mime_types['wav'] = 'audio/wav, audio/x-wav, audio/wave, audio/x-pn-wav';
$mime_types['flac'] = 'audio/flac';
$mime_types['aiff'] = 'audio/aiff, audio/x-aiff, sound/aiff, audio/rmf, audio/x-rmf, audio/x-pn-aiff, audio/x-gsm, audio/mid, audio/x-midi, audio/vnd.qcelp';
return $mime_types;
}
[Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]