<HTML>
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!--
var Planets = new Array(4);
Planets[0] = "Mercury";
Planets[1] = "Venus";
Planets[2] = "Earth";
Planets[3] = "Mars"; var planetEntered = new Array(4);
planetEntered [0] = "36 million miles from earth";
planetEntered [1] = "67 million miles from earth";
planetEntered [2] = "93 million miles from earth";
planetEntered [3] = "141 million miles from earth";
var diameter = new Array(4);
diameter [0] = "The planet Diameter is 3,100 miles";
diameter [1] = "The planet Diameter is 7,700 miles";
diameter [2] = "The planet Diameter is 7.920 miles";
diameter [3] = "The planet Diameter is 4,200 miles";
function getPlanetDistance() {
var selectedPlanet = document.entryForm.entry.value
for ( var i = 0; i < Planets.length; i++) {
if (Planets[i] == selectedPlanet) {
break;
}
}
alert("That planet is " + planetEntered[i] + ". " + diameter[i] +
"."😉;}
// -->
</SCRIPT>
<TITLE>Planet Distance and Diameter</TITLE>
</HEAD>
<BODY>
<FORM NAME="entryForm">
<INPUT TYPE="text" NAME="entry" SIZE="20"><INPUT TYPE="button" VALUE="Find it" onClick="getPlanetDistance()">
</FORM>
</BODY>
</HTML>
to dark templar
Thanks alot man! 😉
I needed this source bad too.
Not sure who ya are but around here if ya got somethin to say to only ONE member you'll find another way to get it to them like an email or private message.
Thread Closed
Ps weed rocks 😉
He said he was in a hurry, I'll make sure he won't do it again. 😉
Originally posted by Dark Templar
He said he was in a hurry, I'll make sure he won't do it again. 😉
No prob man 😉