Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
When setting up a file field to use ONLY remote youtube links, you can't leave the "Allowed file extensions for uploaded files" field blank (it's required).
If I don't want to allow local files, this is not possible.
Also, when creating a node that includes the filefield, there is always still the option to upload a file (which is not desirable).
Comment | File | Size | Author |
---|---|---|---|
#8 | Selection_012.jpg | 150.84 KB | jhedstrom |
Comments
Comment #1
rootworkAgreed, this is confusing. It seems like the current functionality is keyed off of a file upload (although the field type, while categorized under file, is helpfully described as a "media file selector" rather than a "media file upload," which I appreciate!).
The current setup means:
I guess the field was built to allow people to upload videos and choose videos from the web, which is great flexibility! But it would also be nice to have the flexibility of restricting the field to web videos alone.
Comment #2
rootworkSorry, I realized this is really a core Media module issue. I'm moving it over to that queue.
Comment #3
psychobyte CreditAttribution: psychobyte commentedAnyone know of a quick work around to this issue?
Comment #4
psychobyte CreditAttribution: psychobyte commentedNVM. with media-2.x you can select what plugins you want to allow.
Comment #5
sumitmadan CreditAttribution: sumitmadan commentedI want same functionality but I want to hide web tab if I don't select youtube option. Any progress????
Comment #6
J_Andres CreditAttribution: J_Andres commentedFriends, some solution for this?
thanks,
Comment #7
inversed CreditAttribution: inversed commentedI'm not sure how this is handled in Media 2 (per this issue) but there is a solution to hide the Upload tab that is working in my Media 1 implementation. It may be adaptable to the other tabs. You can see it here: https://drupal.org/node/1281486
Comment #8
jhedstromI have a use case that cannot be resolved by hiding the upload tab: we need the WYSIWYG media browser to allow *image* and *document* uploads, but only allow videos from the *web* tab (disallowing direct video upload, but allowing youtube/vimeo). With the latest media 2, there doesn't appear to be any way to configure allowed extensions independent of allowed types
Comment #9
jhedstromI was able to hack around the issue using a form alter to remove video types from the upload tab, yet still allow web uploads:
Comment #10
Dave ReidAs per the screenshot in #8 we added the ability to hide certain media browser tabs, which I think fulfills the original requirement. We can't really handle the advanced logic requested in #8, so custom validation is definitely the way to go (as said in #9).
Comment #12
jaykainthola CreditAttribution: jaykainthola at Kainspire Software commentedHi,
I am also facing same issue. Have anyone found the solution for same?
Thanks