Hi
Does anyone know how to get this javascript code working please?
<script language="JavaScript">
var blnSiteUp="1"
var camera="Please wait for my javascript to check if the webcam is online...";
document.write (camera)
function setblnsiteup()
{
var blnSiteUp="0";
}
</script>
<img id=test onerror="javascript:setblnsiteup();" style="visibility:hidden" src="http://ip.benellis.info/images/bg1.gif">
<script language="JavaScript">
document.write (blnSiteUp)
</script>
<script language="JavaScript">
if (blnSiteUp="0")
{
document.write("site is not up")
}
else if (blnSiteUp="1")
{
document.write("site is up")
}
else
{
document.write("error")
}
</script>
What I want it to do is check if the site is up (by checking the image shown) and report back.
After I manage to get this working I want to add this code to something else that shows a webcam stream (in cgi format) for browsers other than internet explorer and it shows internet explorer an image that updates itself every second ( because IE tries to save the file if its a cgi video stream)
Thanks in advance to anyone that helps!