function CleanURL(ParentURL, WhichWindow)
{
	if(WhichWindow == 'opener'){var windowLocation = new String(opener.location.toString());}
	if(WhichWindow == 'window'){var windowLocation = new String(window.location.toString());}
	if(WhichWindow == 'recall'){var windowLocation = new String(parent.frames.recall.location.toString());}
	if(WhichWindow == 'Frame0'){var windowLocation = new String(parent.Frames[0].toString());}
	if(WhichWindow == 'Frame1'){var windowLocation = new String(parent.Frames[1].toString());}
	if(WhichWindow == 'Frame2'){var windowLocation = new String(parent.Frames[2].toString());}
	if(WhichWindow == 'Frame3'){var windowLocation = new String(parent.Frames[3].toString());}
	
	
	
	var parsingElement = windowLocation.indexOf( "?" );
	var parameters = new Array();
	var parameterValue = unescape(windowLocation.substring( parsingElement + 1 ));
	var TemporaryParam = new Array();
	parameters = parameterValue.split( "&" );
	
											for(i=0; i <  parameters.length; i++)
										{
											TemporaryParam = parameters[i].split( "=");
									
											if (TemporaryParam[0] == ParentURL)
											{
												    if (TemporaryParam[1] == null){return "";} 
													else{return TemporaryParam[1];}
											}
	                                     }

}

