$(document).ready(function () {
    // $("#topics li").hover(
    //    function () {
    //          $(this).find(".thetags").fadeIn(200);
    //        }, 
    //        function () {
    //          $(this).find(".thetags").fadeOut(200);
    //        }
	   
	//);
	
	$("video").each(function(index) {
	     var id = $(this).attr("id");
	     var myPlayer = VideoJS.setup(id, {
         controlsBelow: false, // Display control bar below video instead of in front of
         controlsHiding: false, // Hide controls when mouse is not over the video
         controlsAtStart: false
       });
       myPlayer.onPlay(function(){
         var pid = $(this).attr("id");
             $("video").each(function(index) {
                   var pid = $(this).attr("id");
                   if (pid != id){
                      
                       var vv = this;
                       vv.pause(); 
                   }
                   
               });
       });

    });
	    

	
});

