So I've embedded a video into my WordPress website using the following code
<div class="videoWrapper"><iframe src="http://www.genericwebsitename.co.uk/wp-content/uploads/2015/11/generic-website-name-goes-in-here...mp4" width="300" height="300"></iframe></div>
I have attempted to add autoplay=0, autoplay=false but nothing seems to be working. It always auto plays.
As you can see, this is not a youtube link, the video file is uploaded to the WordPress site itself and linked via a iFrame tag.
Looking through the forums I cannot seem to find an answer that works.
Instead of iframe use bellow format
You can use video tag source, like this:
<video width="640" height="480" controls="controls" type="video/mp4" preload="none">
<source src="http://example.com/mytestfile.mp4" autostart="false">
Your browser does not support the video tag.
</video>
Related
I have using Layer Slider WordPress plugin and added YouTube embed code snippet for showing YouTube video as one slide. i have using a code snippet like below in one layer of this slider,
<iframe width="1400" height="400" src="https://www.youtube.com/embed/E5ln4uR4TwQ?autoplay=0&rel=0&ecver=1" frameborder="0" allowfullscreen></iframe>
it's working. but how to set auto play stop option in video.
also tested the below code by placed &autoplay=0 at the end of the ID.
<iframe width="1400" height="400" src="https://www.youtube.com/embed/E5ln4uR4TwQ&autoplay=0&rel=0&ecver=1" frameborder="0" allowfullscreen></iframe>
Thanks
LayerSlider WP plugin has an option to autoload videos, which can be overriding the autoplay parameter of your embed video.
In the slider you want to put the video, go in the "Slider settings" tab and then choose the "Videos" submenu to enable or disable this option:
how to integrate video.js & VAST, VPAID ADS plugin to wordpress ?
I tried to paste the files in header.php file , but dosent work ?
Please guide on any plugin that works fine .
You can make the videos play on the fly in WordPress pages using the shortcodes.
Videojs HTML5 Player
Embed video file beautifully in WordPress using Videojs HTML5 Player. Embed HTML5 compatible responsive video in your post/page with video js.
https://wordpress.org/plugins/videojs-html5-player/
insert below code to your site Head
<link href="//vjs.zencdn.net/7.10.2/video-js.min.css" rel="stylesheet">
<script src="//vjs.zencdn.net/7.10.2/video.min.js"></script>
you can use of this plugin
then, use below example for post new video
<video
id="my-player"
class="video-js"
controls
preload="auto"
poster="//vjs.zencdn.net/v/oceans.png"
data-setup='{}'>
<source src="//vjs.zencdn.net/v/oceans.mp4" type="video/mp4"></source>
<source src="//vjs.zencdn.net/v/oceans.webm" type="video/webm"></source>
<source src="//vjs.zencdn.net/v/oceans.ogv" type="video/ogg"></source>
<p class="vjs-no-js">
To view this video please enable JavaScript, and consider upgrading to a
web browser that
<a href="https://videojs.com/html5-video-support/" target="_blank">
supports HTML5 video
</a>
</p>
</video>
I want to add mp4 video to my page, but shortcode [video] not workig. I see only string in frontend with:
[video width="640" height="360" mp4="http://localhost:8080/CC/wp-content/uploads/2015/05/movie.mp4"]
Where is the problem ?
Thanks for help.
Try putting the closing shortcode tag [/video] like this
[video width="640" height="360" mp4="http://localhost:8080/CC/wp-content/uploads/2015/05/movie.mp4"][/video]
its shoudnt be a requirement but just in case try it let us know.
You neglected the short-code. You wrote mp4 instead of src
Code corrected:
[video width="640" height="360" src="http://localhost:8080/CC/wp-content/uploads/2015/05/movie.mp4"]
In my case, I was seeing a normal link to the video instead of the video element.
Removing the playsinline attribute from the video tag (which had been added via a PHP filter in my functions.php file) and making sure the video format was correct fixed the issue for me.
How can I autoplay a video using the new embed code style for Youtube?
Months ago my iFrame code including autoplay have worked with my embedded youtube video, but now It won't autoplay my video. I've tried all iFrame possibilities..
Here is my current code:
<iframe width="640" height="385" src="http://www.youtube.com/embed/0319ZgKMLzw?autoplay=1"> </iframe>
I'm using wordpress without any plugins.
I'm in the middle of migrating my current website into Wordpress and was having troubles getting the audio HTML5 tag to work properly. I am basically using a copy and pasted version of the existing code I've been using on the current website (see below, also note I have only edited the source src location to use the entire URL, replaced the php echo, and wrapped the audio tag within a div).
I have also already checked the files to see if they are valid.
Wordpress code:
<div><audio controls="controls" preload="none" onPlay="_gaq.push(['_trackEvent', 'Audio', 'Play', 'Radio-2011-08-01']);">
<source src="http://www.thelovelydaze.com/files/music/TLZRADIO08012011.ogg" type="audio/ogg" />
<source src="http://www.thelovelydaze.com/files/music/TLZRADIO08012011.mp3" type="audio/mp3" />
Your browser does not support audio streaming.
</audio></div>
Current Code:
<audio controls="controls" preload="none" onPlay="_gaq.push(['_trackEvent', 'Audio', 'Play', 'Radio-2011-08-01']);">
<source src="../files/music/TLZRADIO08012011.ogg" type="audio/ogg" />
<source src="../files/music/TLZRADIO08012011.mp3" type="audio/mp3" />
<?php echo $AudioNote ?>
</audio>
For reference:
Wordpress site: http://thelovelydaze.com/WP/2011/08/01/the-lovely-daze-radio-2/
Current site: http://www.thelovelydaze.com/music/tlz-radio-20110801.php
Thanks!
I did not find the html5 js in your site. please add that as still all browsers ar not supporting html 5 and css 3