Conversation
supportHello. Is there any reason this shortcode won’t work? [device-wrapper src=” https://www.youtube.com/watch?v=FW0VdAYF8ro” ; media_type=”video” autoplay=”1″ autoplay_on_view=”1″] I am trying to test playing any video from youtube or vimeo and all it displays instead is the phone mockup with the text “iphone_14_pro_v2”. No video is displayed. Is there something I am missing, or is the plugin not working?
Hello @tubescreamer , To use a YouTube video as a source, you need to provide media_type="iframe" and update your video’s URL to look like this: https://www.youtube.com/embed/YOUR_VIDEO_ID Also please note, that autoplay option is valid only for video media types, not for embedding videos like YouTube or Vimeo. I’ll probably add that feature in the next release though. So to sum up, the correct shortcode for your YouTube video will be like this: [device-wrapper src="https://www.youtube.com/embed/FW0VdAYF8ro" media_type="iframe"]
Ah okay I get it. Thanks! So i’m assuming for Vimeo videos, media_type=”iframe” is to be used as well?
Correct!
Hello @tubescreamer , To use a YouTube video as a source, you need to provide media_type="iframe" and update your video’s URL to look like this: https://www.youtube.com/embed/YOUR_VIDEO_ID Also please note, that autoplay option is valid only for video media types, not for embedding videos like YouTube or Vimeo. I’ll probably add that feature in the next release though. So to sum up, the correct shortcode for your YouTube video will be like this: [device-wrapper src="https://www.youtube.com/embed/FW0VdAYF8ro" media_type="iframe"]
Ah okay I get it. Thanks! So i’m assuming for Vimeo videos, media_type=”iframe” is to be used as well?
Correct!