Add support for .txt attachments
This commit is contained in:
parent
127907e9f5
commit
9167bf18e2
@ -37,6 +37,12 @@ function add_custom_scripts() {
|
||||
}
|
||||
add_action('template_redirect', 'add_custom_scripts');
|
||||
|
||||
function add_mime_types($mime_types) {
|
||||
$mime_types['txt'] = 'text/plain';
|
||||
return $mime_types;
|
||||
}
|
||||
add_filter('upload_mimes', 'add_mime_types', 1, 1);
|
||||
|
||||
function add_search_box($items, $args) {
|
||||
if($args->theme_location == 'header-menu') {
|
||||
ob_start();
|
||||
|
Loading…
Reference in New Issue
Block a user