Hi, Yigit,
I have a hosted video in a tabs section, more precisely in a tab of five.
When video is played if I change active tab, the video continue playing in the background. This is not good.
To pause the video when another card is selected, I wrote the following function and added it as a block of code to the page:
<script>
$(‘.av-tab-section-image’).on(‘click’, function() {
$(‘video’).trigger(‘pause’);
});
</script>
then to remove video loop I changed in section.php file
‘video_loop’ => true,
to
‘video_loop’ => false,
and in video.php file
$output = avia_html5_video_embed($src, $fallback_img);
to
$types = array(‘webm’ => ‘type=”video/webm”‘, ‘mp4’ => ‘type=”video/mp4″‘, ‘ogv’ => ‘type=”video/ogg”‘);
$attributes = array(‘autoplay’ => 0, ‘loop’ => 0, ‘preload’ => ” );
$output = avia_html5_video_embed($src, $fallback_img, $types, $attributes);
Everything works properly!
Any other suggestions?
Regards
Lion
Hey lion73,
Could you please give us a link to your website, we need more context to be able to help you.
Best regards,
Victoria
Sorry Victoria, you do not know what you’re talking about.
The message was not for you.
Like so many times, you show the lack of knowledge of the code and of the theme!
Your responses to comments are just a waste of time for those who read them!