Click here to Skip to main content
15,891,431 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Does anyone know how to send a signal via jquery/java to stop the movie from playing/pausing etc..



HTML
<!DOCTYPE html>
<html>
<head>
  <title>Video.js | HTML5 Video Player</title>

  <!-- Chang URLs to wherever Video.js files will be hosted -->
  <link href="video-js.css" rel="stylesheet" type="text/css">
  <!-- video.js must be in the <head> for older IEs to work. -->
  <script src="video.js"></script>
  <script src="jquery-1.11.0.js"></script>

  <!-- Unless using the CDN hosted version, update the URL to the Flash SWF -->
  <script>
    //videojs.options.flash.swf = "video-js.swf";
    videojs.options.flash.swf = "Module1.swf";
  </script>
  
  <script>
    $(document).ready(function()
    {
      $("#Tester").mousedown(
      function()
      {   
        //What need to be placed here to cause the media to pause
      	//$("#example_video_1").media.pause();
        
        //new MediaElement(v, {success: function(media) {    media.pause();}});
        
      });
    });
  </script>


</head>
<body>

  <video id="example_video_1" class="video-js vjs-default-skin" controls preload="none" width="640" height="264"
      
      data-setup="{}">
    <source src="Module1.swf" type='video/flv' />
    <track kind="captions" src="demo.captions.vtt" srclang="en" label="English"></track><!-- Tracks need an ending tag thanks to IE9 -->
    <track kind="subtitles" src="demo.captions.vtt" srclang="en" label="English"></track><!-- Tracks need an ending tag thanks to IE9 -->
  </video>
  
  
  <div ID="Tester">
    Click This
  </div>

</body>
</html>
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900