| Server IP : 23.94.149.180 / Your IP : 216.73.216.147 Web Server : nginx/1.20.1 System : Linux deadrock 5.14.0-741.22.1.el9_9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Nov 12 15:18:14 UTC 2026 x86_64 User : nginx ( 991) PHP Version : 8.6.0 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /files/www/hacklab/peterson/ |
Upload File : |
<html>
<head>
<script language = "JavaScript">
<!--Begin JavaScript hide
/*JavaScript Homework #5 Page 1 CIS25, Spring 2000, Thursday evening class
Using Netscape 4.7
by: Linda Peterson
URL: http://www.hacklab.net/peterson/
*/
var catalogs = 0 // index of free catalogs
var favorite = "" // catalog requested
/* Find out which catalog was selected by looking at
the array of the select box named choice.
Save that number in a variable and use the variable
to get the value property of the select box.
*/
function processinfo(){
catalogs = document.catalog.choice.selectedIndex
favorite = document.catalog.choice[catalogs].value;
alert ("You have chosen the " + favorite + " catalog.");
var choice = new String() // create a variable to hold the user's catalog choice
choice=favorite
document.cookie="CatalogCookie=" + escape(choice) // store the heading CatalogCookie followed by the users selection
}
function displayCookie(){
var CatalogCookie = new String() // create a variable to hold the cookie
CatalogCookie = unescape(document.cookie) // get the cookie from the disk
alert ("You entered this cookie.\n" + CatalogCookie) // show the user the cookie
}
// end JS hide -->
</script>
</head>
<body background="IvyBG.gif">
<center><img src="GardTitle.gif" width="556" height="128"></center>
<div id="CatDesc" style="position:absolute; left:100; top:150">
<H3> For a limited time we are offering a free catalog following are a list of available titles.
Please select the catalog you are interested in and then click the next page text. Sorry only one catalog per household is free of charge. </H2>
</div>
<!-- Create a group form named catalog.
Javascript uses document. catalog to get information from the form.-->
<form name="catalog" >
<!-- Create a select list named document.catagory.choice
Javascript access these buttons by saying document.catalog.choice[ ]
-->
<p> <p> 
<br><p><H4>
Select your free catalog here.</p>
<br>
<br>
<select name="choice" size=3>
<option value="Seeds" selected> Seeds From Around The World
<option value="Bareroot"> Bare Root Plants
<option value="Tools"> Gardners Favorite Tools
</select>
<br> <br>
<br>
<input type="button" onClick="processinfo()" value="Click to complete request">
<a href="Hwk5P2.html">Take me to the next page.</a>
</form>
<p><a href="javascript:displayCookie()"> Show me my cookie. <a/>
</body>
</html>