// Use a javascript timer to check and see if the Flash movie has loaded.
// If so, the image name is passed to the Flash object.
// This method was implemented to work with Safari/NS loading the dynamic image.
// Otherwise the first image would NOT load in Safari and Netscape browsers most of the time. 

var qs = new Querystring();
var pageRequest = qs.get("page");
//alert(pageRequest);
schedule("productFeatures", "getProductFeatureImage(\"batteries\")\;");

function schedule(objectID, functionCall) //this function looks for the Flash object to load on the home page every 200ms.
{
	if (document.getElementById(objectID))
	{
//		alert(pageRequest);
		eval(functionCall); //call the function that was passed in if Flash object has loaded.

	} else {

		setTimeout("schedule('" + objectID + "', '" + functionCall + "')", 200); //wait 200ms and look again.
	}
	return true;
}
