Skip to content

Instantly share code, notes, and snippets.

@kabbo508
Created July 18, 2020 21:26
Show Gist options
  • Save kabbo508/2d4f31d6fe0c281728ec71374c6f638b to your computer and use it in GitHub Desktop.
Save kabbo508/2d4f31d6fe0c281728ec71374c6f638b to your computer and use it in GitHub Desktop.
//** *Enable upload for webp image files.*/
function webp_upload_mimes($existing_mimes) {
$existing_mimes['webp'] = 'image/webp';
return $existing_mimes;
}
add_filter('mime_types', 'webp_upload_mimes');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment