Home>Support>Media uploaded – File – not working correctly

Media uploaded – File – not working correctly

Notice: This thread is over two years old; the information may be outdated. Please consider creating a new thread if you require free support. If you have an active SiteOrigin Premium license, you can email our premium support desk at [email protected].

Hi

I have created my own widget but I am struggling to get the file uploader to work correctly. I want to give the user the option to select documents from their media library but when I specify file as the library the upload dialog box is returning no files.

If I choose ‘image’ as the library then I can choose from any of the images already uploaded so it is just an issue with the library detection seemingly.

Here is the field initialisation code I am using:

'file' => array(
	'type' => 'media',
	'library' => 'file',
	'image_search' => false,
	'label' => __('File', 'so-widgets-bundle'),
	'description' => __('Choose the uploaded file.', 'so-widgets-bundle'),
)

Thanks,
James

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 8 years, 10 months ago Andrew Misplon
    Hi, I Work Here

    Hi James

    Thanks for posting and for checking out the Widgets Bundle. Hopefully, you’ve made progress since posting. We’d really like to offer support for this sort of problem but at the moment are stretched and unfortunately, are focussing on standard end use questions. Hopefully, we’ll be able to provide help for dev level questions soon.

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More