// Function to allow one JavaScript file to be included by another.
function IncludeJavaScript(jsFile)
	{
	document.write('<script type="text/javascript" src="' + jsFile + '"></scr' + 'ipt>'); 
	}

/*
 * Copyright ButterflyVista Corporation
*/
// Handler: Do Buy Now button.
function DoBuyNow(IDControl)
	{
	var lIDBuyNow;
	var strURLBuyNow, strControlID;


	// Check for no arguments.
	if (!IDControl  ||  "" == IDControl)
		{
		// Assume the first ID.
		IDControl = "1";

		// Compute the control ID.
		strControlID = GlobalIDSelBuyNow+IDControl;

		// Get the buy now ID.
		IDBuyNow = document.getElementById(strControlID).value;
		}
	else
		{
		// Compute the control ID.
		strControlID = GlobalIDSelBuyNow+IDControl;

		// Get the currently selected item.
		IDBuyNow = document.getElementById(strControlID).value;
		}

	// Get the purchase URL for the option.
	switch (parseInt(IDBuyNow))
		{
		case IDBuyJobFish_Opt1:
			// Get the address to the appropriate shopping cart.
			strURLBuyNow = GlobalBuyJobFishOpt1;

			// Go to the appropriate shopping cart.
			window.open( strURLBuyNow, "buynow" );

			break;

		case IDBuyJobFish_Opt2:
			// Get the address to the appropriate shopping cart.
			strURLBuyNow = GlobalBuyJobFishOpt2;

			// Go to the appropriate shopping cart.
			window.open( strURLBuyNow, "buynow" );

			break;

		case IDBuyJobFish_Life:
			// Get the address to the appropriate shopping cart.
			strURLBuyNow = GlobalBuyJobFishLife;

			// Go to the appropriate shopping cart.
			window.open( strURLBuyNow, "buynow" );

			break;

		case IDBuyJobFish_Suite:
			// Get the address to the appropriate shopping cart.
			strURLBuyNow = GlobalBuyJobFishSuite;

			// Go to the appropriate shopping cart.
			window.open( strURLBuyNow, "buynow" );

			break;

		default:
			$strURLBuyNow = "";
		}
	}

function DoBuyNowMetricWiz()
	{
	var strURLBuyNow;


	// Get the address to the appropriate shopping cart.
	strURLBuyNow = GlobalBuyMetricWiz;

	// Go to the appropriate shopping cart.
	window.open( strURLBuyNow, "buynow" );
	}

function DoBuyNowOfficeDove()
	{
	var strURLBuyNow;


	// Get the address to the appropriate shopping cart.
	strURLBuyNow = GlobalBuyOfficeDove;

	// Go to the appropriate shopping cart.
	window.open( strURLBuyNow, "buynow" );
	}

