﻿
// JScript File
function videoPreview(path)
{
    var newwindow;
   if (newwindow != null) 
    {
        if(newwindow.closed==false)
            newwindow.close();
    }    
   
 //  alert(path);
    //alert(img.src);
  
   //alert(height+"*---------"+width);
    newwindow=window.open('', '','location=0, menubar=0, resizable=1, scrollbars=1, status=0,titlebar=0, toolbar=0, height=400, width=470');
   // newwindow.moveTo(0,0);
    var htmlString="<html><head><title>Preview Video</title></head><body>";
        htmlString+="<table cellspacing='0' cellpadding='0' border='0' align='center'>";
        htmlString+="<tr><td align='center'>";
        
         htmlString += "<object id='Object1' type='application/x-oleobject' width='370' height='320' standby='Loading Microsoft Windows Media Player components...' codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,7,1112' classid='clsid:6BF52A52-394A-11d3-B153-00C04F79FAA6'>"
                         + "<param name='URL' value='"+path+"' />"
                         + "<param name='rate' value='1' />"
                         + "<param name='balance' value='0' />"
                         + "<param name='currentPosition' value='0' />"
                         + "<param name='defaultFrame' />"
                         + "<param name='playCount' value='1' />"
                         + "<param name='autoStart' value='0' />"
                         + "<param name='currentMarker' value='0' />"
                         + "<param name='invokeURLs' value='-1' />"
                         + "<param name='baseURL' />"
                         + "<param name='volume' value='100' />"
                         + "<param name='mute' value='0' />"
                         + "<param name='uiMode' value='full' />"
                         + "<param name='stretchToFit' value='-1' />"
                         + "<param name='windowlessVideo' value='0' />"
                         + "<param name='enabled' value='-1' />"
                         + "<param name='enableContextMenu' value='0' />"
                         + "<param name='fullScreen' value='0' />"
                         + "<param name='SAMIStyle' />"
                         + "<param name='SAMILang' />"
                         + "<param name='SAMIFilename' />"
                         + "<param name='captioningID' />"
                         + "<param name='enableErrorDialogs' value='0' />"
                         + "<param name='_cx' value='10319' />"
                         + "<param name='_cy' value='9049' /> "
                         +"<embed  type='application/x-mplayer2' pluginspage='http://www.microsoft.com/Windows/MediaPlayer/'"
                         +"name='mediaplayer1' showcontrols='false' showstatusbar='true' enablecontextmenu='false'"
                         + "autostart='true' width='370' height='320' loop='false' src='"+path+"' />"
                         + "</object>";
        
        htmlString+="</td</tr><tr><td>&nbsp;</td></tr><tr><td align='center'>";
        htmlString+="<img src='images/inner/closebtn.jpg' style='cursor:pointer' onclick=\"javascript:window.close()\" />";
        htmlString+="</td>";
        htmlString+="</tr></table></body></html>";
    newwindow.document.write(htmlString);
    newwindow.document.close();
    if (window.focus)
	{
		newwindow.focus();
	}
}

function videoPreviewLaerge(path)
{
    var newwindow;
   if (newwindow != null) 
    {
        if(newwindow.closed==false)
            newwindow.close();
    }    
   
 //  alert(path);
    //alert(img.src);
  
   //alert(height+"*---------"+width);
    newwindow=window.open('', '','location=0, menubar=0, resizable=1, scrollbars=1, status=0,titlebar=0, toolbar=0, height=580, width=700');
   // newwindow.moveTo(0,0);
    var htmlString="<html><head><title>Preview Video</title></head><body>";
        htmlString+="<table cellspacing='0' cellpadding='0' border='0' align='center'>";
        htmlString+="<tr><td align='center'>";
        
         htmlString += "<object id='Object1' type='application/x-oleobject' width='648' height='504' standby='Loading Microsoft Windows Media Player components...' codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,7,1112' classid='clsid:6BF52A52-394A-11d3-B153-00C04F79FAA6'>";
                           htmlString += "<param name='URL' value='"+path+"' />";
                           htmlString += "<param name='rate' value='1' />";
                           htmlString += "<param name='balance' value='0' />";
                           htmlString += "<param name='currentPosition' value='0' />";
                           htmlString += "<param name='defaultFrame' />";
                           htmlString += "<param name='playCount' value='1' />"
                         + "<param name='autoStart' value='0' />"
                         + "<param name='currentMarker' value='0' />"
                         + "<param name='invokeURLs' value='-1' />"
                         + "<param name='baseURL' />"
                         + "<param name='volume' value='100' />"
                         + "<param name='mute' value='0' />"
                         + "<param name='uiMode' value='full' />"
                         + "<param name='stretchToFit' value='-1' />"
                         + "<param name='windowlessVideo' value='0' />"
                         + "<param name='enabled' value='-1' />"
                         + "<param name='enableContextMenu' value='0' />"
                         + "<param name='fullScreen' value='0' />"
                         + "<param name='SAMIStyle' />"
                         + "<param name='SAMILang' />"
                         + "<param name='SAMIFilename' />"
                         + "<param name='captioningID' />"
                         + "<param name='enableErrorDialogs' value='0' />"
                         + "<param name='_cx' value='10319' />"
                         + "<param name='_cy' value='9049' /> "
                         +"<embed  type='application/x-mplayer2' pluginspage='http://www.microsoft.com/Windows/MediaPlayer/'"
                         +"name='mediaplayer1' showcontrols='false' showstatusbar='true' enablecontextmenu='false'"
                         + "autostart='true' width='648' height='504' loop='false' src='"+path+"' />"
                         + "</object>";
        
        htmlString+="</td</tr><tr><td>&nbsp;</td></tr><tr><td align='center'>";
        htmlString+="<img src='images/inner/closebtn.jpg' style='cursor:pointer' onclick=\"javascript:window.close()\" />";
        htmlString+="</td>";
        htmlString+="</tr></table></body></html>";
    newwindow.document.write(htmlString);
    newwindow.document.close();
    if (window.focus)
	{
		newwindow.focus();
	}
}

