Skip to content

Instantly share code, notes, and snippets.

@thejamescollins
Created April 2, 2014 02:54
Show Gist options
  • Save thejamescollins/9927208 to your computer and use it in GitHub Desktop.
Save thejamescollins/9927208 to your computer and use it in GitHub Desktop.
Allow the .4w7 file type to be uploaded to the WordPress media library
<?php
/**
* Allow the .4w7 file type to be uploaded to the WordPress media library.
*
* Ref: https://gist.github.com/om4james/9927208
*
* Put this snippet into a child theme's functions.php file
*/
function rasq_myme_types( $mime_types ){
$mime_types['4w7'] = 'application/octet-stream';
return $mime_types;
}
add_filter( 'upload_mimes', 'rasq_myme_types' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment