// JavaScript Document

function headerImage(im) {
	$('headerImage').innerHTML = '<img src="'+im+'">';
}

function showCamera() {
	
	if ((navigator.appName == "Microsoft Internet Explorer")&&(navigator.platform != "MacPPC")&&(navigator.platform != "Mac68k")) {
               
			   document.write('<p>Please note that if you are using Internet Explorer, an ActiveX control will be downloaded. You must allow this to install in order to see the webcam. <br>Download may take several minutes.</p>');
			   
			    document.write("<OBJECT ID=\"AxisCamControl\" CLASSID=\"CLSID:917623D1-D8E5-11D2-BE8B-00104B06BDE3\" WIDTH=\"704\" HEIGHT=\"576\" CODEBASE=\"http://80.25.14.132:8150/activex/AxisCamControl.cab#Version=2,20,0,6\">");
                document.write("<PARAM NAME=DisplaySoundPanel VALUE=0>");
                document.write("<PARAM NAME=URL VALUE=\"http://80.25.14.132:8150/axis-cgi/mjpg/video.cgi?camera=&resolution=704x576\">");
	    
                document.write("</OBJECT>");
	
  } else {
    theDate = new Date();
        var output = "<img HEIGHT=576\" WIDTH=704 SRC=\"http://80.25.14.132:8150/axis-cgi/mjpg/video.cgi?camera=&resolution=704x576&";
    output += theDate.getTime()
    output += "\" ALT=\"Press Reload if no image is displayed\">";
    document.write(output);
  }


}

function showHpPopup() {

if ($$('#hpop img')) {
var hpopup = document.getElementById('hpop');
var hcontent = hpopup.innerHTML;
//alert(hcontent);
hpopup.style.display='none';
document.write('<div id="hpopcontainer" style="position:absolute; z-index:9999; "><div style="background-color:white; width:527px; height:400px; position:relative; left:28%; top:14px;" class="hpopup"><div style="position:absolute; width:100%"><div align="right" style="padding:12px;"><a style="background-color:#0C347F; padding:4px; border: solid 3px white; text-decoration:none; color:white;" href="javascript:void(0);" onclick="hideHpPopup();">CLOSE</a></div></div><div>'+hcontent+'</div></div></div>');	
}	
}

function hideHpPopup() {
try {
$('hpopcontainer').hide();
} catch (e) {	
}
}



