-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathapplet.html
40 lines (32 loc) · 877 Bytes
/
applet.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<head>
<title>Hecl interpreter in an applet</title>
<script>
function runHecl() {
s = document.sf.scriptin.value;
applet = document.getElementById("heclet");
applet.runScript(s);
}
// -->
</script>
</head>
<body>
<h1 align="center">Hecl Applet</h1>
<p>Enter text in the first box, and click to see it run.</p>
<b>Script:</b><br/>
<form name="sf" action="">
<p>
<textarea name="scriptin" rows="20" cols="80" style="width: 100%">set i 0
while {< &i 10} {
puts "i is $i"
incr &i
}</textarea><br/>
<input onclick="runHecl()" type="button" value="Evaluate Script"/>
</p>
</form>
<applet id="heclet" name="heclApplet" code="org.hecl.applet.HeclApplet"
archive="HeclApplet.jar" width="600" height="200">
</applet>
</body>
</html>