<!-- Begin

NL = "\n"

function randomIndex(nchoices) 
{ 
	return Math.floor((Math.random() * nchoices) % nchoices)
}

function randomItem(items)
{
	itemList = items.split(/;/)
	return itemList[randomIndex(itemList.length)]
}

function recipe()
{
	fish = randomItem("salmon;halibut;sole;flounder;trout filets;shrimp;scallops;monkfish;catfish;sea bass;monkfish")
	flour = randomItem("flour;rice flour;fine cornmeal;instant potato flakes;crushed corn flakes")
	nut = randomItem("pine nuts;almonds;macadamia nuts;soybeans;cashews;hazelnuts;pistachio nuts")
	herb = randomItem("chervil;parsley;chives;tarragon;fresh oregano;rosemary")
	oil = randomItem("olive oil;butter;EVOO;canola oil;roasted sesame oil;peanut oil")
	onion = randomItem("onion;shallots;scallions;garlic;leeks;red onions")
	
	description = "Recipe for " + fish + " and " + herb

	ingredients = 
		"12 ounces of " + fish + NL +
		"4 tbsp. of " + flour + NL +
		"4 tbsp. of " + oil + NL +
		"1 tbsp. chopped " + onion + NL +
		"2 tbsp. chopped " + herb + NL +
		"2 tbsp. crushed or pieces, " + nut + NL +
		"salt and ground pepper to taste"



procedure = "1) Heat a non stick pan over medium high heat. " +
		"Dip the "+ fish +" in "+ flour +" on both sides and shake off the excess. " +
		"Add the "+ oil +" and when it's hot, add the "+ fish +" and cook 2 or 3 minutes on each side. " + 
		"Place the cooked "+ fish +" on a serving plate. " +
		"Add the "+ nut +", cook and stir for 20 seconds. " +
		"When they are lightly toasted, add the "+ onion +" and cook 15 seconds more. " +
		NL + NL +
		"2) Lower the burner to medium low. " + 
		"Add the "+ herb +" and a few pinches of salt and pepper. " +
		"Cook and stir until the "+ herb +" has wilted. " +
		"Put the "+ nut +" and "+ herb +" mixture on top of the cooked "+ fish +". " +
		NL + NL +
		"3) Serve. "

	credit = "Copyright 2008"
	
return description + NL + NL +

			"Ingredients" + NL + NL + ingredients + NL + NL +
		"Procedure" + NL + NL + procedure + NL + NL +
		credit + NL
}

function generateRecipe()
{
	document.askforrecipe.result.value = recipe()
}
  //  End -->
