//to enable and disable the div in Omniplayer hen user clicks on next & prev arrows.
function disp_omni(tot,val)
{ 
  for(var i=0; i<tot;i++)
  {
      if(i!= val)
      {
        document.getElementById("omnidisplay_"+i).style.display = "none";
      }
			else
        document.getElementById("omnidisplay_"+i).style.display = "";
  }
}

if(Drupal.jsEnabled) {
  $(document).ready(
    function(){
     /**/

			$.ajax({
				type: "POST",
				url: "/omniplayer/ajax/",	
				
				data: "node_type=" + node_type+ "&node_nid=" + node_nid,
				dataType: 'json',
				success: function(data){
					
				
					if (data.content=="NO DATA"){
						$("#ilw_omniplayer_widget_placeholder").css( "display", "none" );
					}else{
						$("#ilw_omniplayer_widget_placeholder").html(data.content);  
					}
				},
				error: function (xmlhttp) {
						// alert('An HTTP error '+ xmlhttp.status +' occured.\n /omniplayer/ajax/ where nid ='+node_nid+'and node_type ='+node_type);
				}
			});	  
    }
  );
  
}
