I have the following script which starts running when i click on record button . I want to show a image when i click on record button which is same as the one displayed usually when we upload images on... this is the script:
<script>
function st()
{
if (window.XMLHttpRequest)
{
xmlhttp=new XMLHttpRequest();
}
else
{
xmlhttp=new ActiveXObject('Microsoft.XMLHTTP');
}
xmlhttp.onreadystatechange=function()
{
if (xmlhttp.readyState==4 && xmlhttp.status==200)
{
alert('RECORDING Start');
}
}
xmlhttp.open('GET','http://localhost/IPCAM/start.php;)
xmlhttp.send();
setTimeout('st()',5000);
}
</script>
And this the button when i click on this button the ajax starts background.
<button OnClick="st()">Record</button>
I have no Idea to do this please can someone help me .