
	 
	var nTimer ;
	var lifeofView = 10;

	function Play() {
		window.clearInterval(nTimer);

		NV1.MediaType = 4 ;		
		NV1.ID = 1 ;
		NV1.SetActive(1);
		NV1.DisplayTitleBar(0);

//<!--LOGIN RELATED CHANGES BEGIN------------------------------------------------------------------------------>
NV1.MediaSource = "207.118.58.151";	//NOTE=> Input your Video Server IP
		NV1.MediaUserName = "guest";		//NOTE=> Input your Video Server User Name
		NV1.MediaPassword = "1234";		//NOTE=> Input your Video Server Password
		NV1.Httpport = 80;			//NOTE=> Input your Video Server Http Port
		NV1.RegisterPort = 6000;		//NOTE=> Input your Video Server Register Port
		NV1.ControlPort = 6001;		//NOTE=> Input your Video Server Control Port
		NV1.StreamingPort = 6002;		//NOTE=> Input your Video Server Streaming Port 
		NV1.MulticastPort = 5000;		//NOTE=> Input your Video Server Multicast Port

		NV1.Vendor="PELCO";			//NOTE=> Input your PTZ Vendor, IN CAPTICALS
		NV1.Protocol="PELCO-P";			//NOTE=> Input your PTZ Protocol, IN CAPTICALS
		NV1.AddressID="1";			//NOTE=> Input your PTZ Address ID
NV1.PTZPostMode="1";
		NV1.Parity="N81";			//NOTE=> Input your PTZ Parity
		NV1.BaudRate="9600";			//NOTE=> Input your PTZ Baudrate

		NV1.Connect() ;
		NV1.Play() ;

		if (NV1.ContentStatus>=2) {
			NV1.DisablePTZ();			//NOTE=> Enable/Disable PTZ
			NV1.DisableMousePTZ();		//NOTE=> Enable/Disable Mouse PTZ
			setInterval("chgTimer()", 1000);//Start the Count dowm

		}
	}
		
		var nLivingTime = 10;		           
//<!--LOGIN RELATED CHANGES END------------------------------------------------------------------------------>

	function chgTimer() {
		nLivingTime-- ;
		txtLiving.innerText = 'Connection will timeout in ' + nLivingTime + ' sec' ;
		if (nLivingTime == 0 ) { txtLiving.innerText = 'Connection has timed out ... Please Refresh'  ; NV1.Disconnect() ;	alert ('Please Refresh Connection'); }
		if (nLivingTime <0)  txtLiving.innerText = 'Connection has timed out ... Please Refresh'; 	//NOTE==> Enable/Disable close the live demo window
}
	function winClose() {
		NV1.Disconnect() ;
		window.opener=null ;
		window.close() ;
	}

	
	nTimer=setInterval("window.Play()",100);
	out_play_wm();
	
	function chkMouse() {
		if ( event.button == 2 ) {
			alert('The right mouse button was locked');	//NOTE ==> Disable right mouse button
			return false ;								//NOTE ==> Disable right mouse button
			
			// return true ;	//NOTE ==> Enable right mouse button
		}
	}	
	
	function refresh_page () {
	
	NV1.Disconnect() ;
	history.go(); }
	
	

	
function out_play_wm(){
	
document.writeln('<div align="center"  width="590px" style="font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#000000;"><br/><strong>WebCam Stream Courtesy of</strong> <a class="style2" href="http://purealtar.com" target="_blank">Pure Altar Productions</a> <strong>&copy;&nbsp;Copyright 2008</strong> <br/><br/></div>'); }
	
	    // convert all characters to lowercase to simplify testing
    var agt=navigator.userAgent.toLowerCase();

    // *** BROWSER VERSION ***
    // Note: On IE5, these return 4, so use is_ie5up to detect IE5.
	
    var is_major = parseInt(navigator.appVersion);
    var is_minor = parseFloat(navigator.appVersion);
	
    var is_ie     = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
    var is_ie3    = (is_ie && (is_major < 4));
    var is_ie4    = (is_ie && (is_major == 4) && (agt.indexOf("msie 4")!=-1) );
    var is_ie4up  = (is_ie && (is_major >= 4));
    var is_ie5    = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0")!=-1) );
    var is_ie5_5  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.5") !=-1));
    var is_ie5up  = (is_ie && !is_ie3 && !is_ie4);
    var is_ie5_5up =(is_ie && !is_ie3 && !is_ie4 && !is_ie5);
    var is_ie6    = (is_ie && (is_major == 4) && (agt.indexOf("msie 6.")!=-1) );
    var is_ie6up  = (is_ie && !is_ie3 && !is_ie4 && !is_ie5 && !is_ie5_5);
	

	

  