Support

Account

Home Forums General Issues Single field for youtube, vimeo, or video URL on server?

Solved

Single field for youtube, vimeo, or video URL on server?

  • I’m planning on doing the following and wondering if there is a field to simplify the code. I’ll use a text area field which will take either youtube, or vimeo embed snippets, youtube or vimeo video URLs, or a URL to a video uploaded to the server mp4 or any other format.

    Conditional statements in the post templates will check the field, and if a snippet is used output the snippet. If a URL to a youtube/vimeo video or mp4 or other format is in the field use an HTML5 player.

    Is there a field type which would display a drop down and based on the drop down selection show either a text input, or text area so that my conditionals would only need to check if fields were empty or not rather than checking if they contain a URL or snippet which is a little more coding?

    Thanks

  • Hi @anagio

    This media field is yet to be created for the ACF plugin.

    Someone has made a YouTube field on github, perhaps that would be a good start to look at?

    Good luck

    Thanks
    E

  • Thank @elliot i’ll just use a text area and conditionals in the template. I don’t think ACF needs a special field for videos, I was just wondering if any field could display a drop down and show / hide an input based on the select option.

  • Hi,

    i found this work and it seems interesting https://bitbucket.org/jupitercow/acf-vimeo-uploader-field

    @elliot
    do you know this plugin ?

  • Hi @benoit

    Thanks for the share. Looks like it would be pretty powerful!

    Thanks
    E

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘Single field for youtube, vimeo, or video URL on server?’ is closed to new replies.