Brianstein
07-27-2003, 10:31 PM
Ok im stuck because im doin 101 stupid ways to die and i have 101 .swf files and i want the user to put a number (1-101) in a text field then click subit and it loads the correct file in another frame. all the .swf files are name 1.swf, 2 .swf, 3 .swf, etc.
here is what i have so far but it is VERY buggy:
<html>
<head>
<title>101 Stupid Ways to Die</title>
<script>
<!------------
function loadSwf(helloFoo) {
document.writeln('<a href=' + '"' + helloFoo + '.html' + '"' + '>Click Here to see the way</a>');
}
------------------>
</script>
</head>
<body>
<form name="pickForm" onSubmit="loadSwf(parent.document.pickForm.numberToLoad)">
<input type="text" name="numberToLoad" value="1" onChange="loadSwf(this);">
<input type="button" value="Load the Stupid Way to Die" onClick="loadSwf(this);">
<input type="submit" value="Submit">
</form>
</body>
</html>
here is what i have so far but it is VERY buggy:
<html>
<head>
<title>101 Stupid Ways to Die</title>
<script>
<!------------
function loadSwf(helloFoo) {
document.writeln('<a href=' + '"' + helloFoo + '.html' + '"' + '>Click Here to see the way</a>');
}
------------------>
</script>
</head>
<body>
<form name="pickForm" onSubmit="loadSwf(parent.document.pickForm.numberToLoad)">
<input type="text" name="numberToLoad" value="1" onChange="loadSwf(this);">
<input type="button" value="Load the Stupid Way to Die" onClick="loadSwf(this);">
<input type="submit" value="Submit">
</form>
</body>
</html>