<html>
<head>
<script language="Javascript" type="text/javascript">
var data = new Array();
function pingTimeoutData(){
var i = 0;
var datafile = window.location.href.substring(0,
window.location.href.lastIndexOf("/") + 1) +
"data.txt";
var url = new java.net.URL(datafile);
var connect = url.openConnection();
var input = new java.io.BufferedReader(
new java.io.InputStreamReader(
connect.getInputStream()));
var aLine = ""
while((aLine = input.readLine()) != null) {
data[i++] = aLine;
}
}
</script>
<script type="text/javascript">
/**/var i=0;
function await_9(){
pingTimeoutData();
/**/document.getElementById('txt').value=++i + "\t\t\t" + data[0];
if (data[0] == 9){
//document.getElementById('txt').value="PLAY!";
//document.movie1.Play();
setTimeout("await_9()",data[0] * 1000);
}else if(data[0] == 8){
//document.movie1.Rewind();
//document.movie1.Stop();
//document.movie1.Rewind();
setTimeout("await_9()", 1000);
}else{
setTimeout("await_9()",data[0] * 1000);}
}
</script>
<title>RTF 331: Soundscapes Project 1</title>
<style>
body {
background:black;
/*overflow:hidden;*/
}
table{
margin-left: auto;
margin-right: auto;
text-align: left;
}
</style>
</head>
<body>
<table>
<tr>
<td>
<OBJECT classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
codebase="http://www.apple.com/qtactivex/qtplugin.cab"
width="180" height="160"
id="movie1" >
<PARAM name="scale" value="tofit">
<EMBED width="800" height="600"
src="My.mov"
name="movie1"
autoplay="false"
enablejavascript="true">
</EMBED>
</OBJECT>
</td>
</tr>
</table>
<input type="text" id="txt" />
<script type="text/javascript">
await_9();
</script>
</body>
</html>