Closed leurdo closed 5 years ago
Not sure but by default the media field is set to handle image
type only. Perhaps adding the application
file type to the media field will let you select it for use in the media field.
Dear Sir, I tried this. Here is my metabox:
Metabox::make(__('Popup', 'lzd'), 'post', [ 'context' => 'side', 'priority' => 'low' ]) ->set([ Field::media('popup_image', [ 'title' => __('Popup Image', 'lzd'), 'type' => ['image', 'application'] ]) ]);
And other application types (pdf for example) can be selected, but not the svg.
I've got the same problem in my project : I find a code for displaying .svg file in media select but when I pressed 'Insert', the file doesn't appear. https://github.com/mvpdesign/themosis-theme/blob/master/app/admin/svg.php
@Xaotome @leurdo A PR with a fix is in progress regarding this issue. Will be fixed soon.
Current 2.0 beta release allows the upload of svg images to the media field now.
Hello, I have a problem with svg images. I added them to the list of allowed files extensions, so I can upload them to Wordpress Media Library. But I still can not upload them to Themosis Media Field. How to make this possible? Many thanks.