This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Playing Video on Start -Up
#2
Via Custom JavaScript. Change video source as needed. This script will only affect Usermode visualization but not Touch, Schedulers or Trends.
Code:
$(function(){
  if ($('body').hasClass('usermode')) {
    var src = 'https://interactive-examples.mdn.mozilla.net/media/cc0-videos/flower.mp4';
    
    var el = $(
      '<video muted="true" autoplay="true">' +
        '<source src="' + src + '" type="video/mp4">' +
      '</video>'
    ).css({
      'position': 'absolute',
      'top': 0,
      'left': 0,
      'width': '100%',
      'height': '100%',
      'z-index': 9999,
      'background': 'white'
    }).appendTo('body');
    
    el.on('ended click', function() {
      el.off();
      
      el.css({
        'transition': '0.5s',
        'opacity': 0
      });
      
      setTimeout(function() {
        el.remove();
      }, 500);
    });
  }
});
Reply


Messages In This Thread
Playing Video on Start -Up - by mkaymak - 11.04.2022, 08:49
RE: Playing Video on Start -Up - by admin - 11.04.2022, 09:07
RE: Playing Video on Start -Up - by mkaymak - 11.04.2022, 09:22
RE: Playing Video on Start -Up - by admin - 11.04.2022, 09:22
RE: Playing Video on Start -Up - by mkaymak - 11.04.2022, 09:24
RE: Playing Video on Start -Up - by mkaymak - 28.04.2022, 06:48
RE: Playing Video on Start -Up - by admin - 28.04.2022, 07:06
RE: Playing Video on Start -Up - by mkaymak - 28.04.2022, 07:51
RE: Playing Video on Start -Up - by admin - 28.04.2022, 07:55
RE: Playing Video on Start -Up - by mkaymak - 28.04.2022, 11:47
RE: Playing Video on Start -Up - by admin - 28.04.2022, 12:03
RE: Playing Video on Start -Up - by mkaymak - 28.04.2022, 12:08
RE: Playing Video on Start -Up - by admin - 28.04.2022, 12:38
RE: Playing Video on Start -Up - by mkaymak - 27.05.2022, 07:14

Forum Jump: