//Web Ignite - frames redirect method #3
//main-frame JavaScript
//set FrameSetUrl below to location of frameset page

var FrameSetUrl="index.htm"

if(top == self) {
	document.cookie="WiLoadPage="+escape(self.location.href)+"; path=/";
	self.location.replace(FrameSetUrl);}
else {
	var WiAllCookies = document.cookie;
	var WiStart = WiAllCookies.indexOf("WiLoadPage=");
	if (WiStart != -1) {
		WiStart = WiStart + 11
		var WiEnd = WiAllCookies.indexOf(";", WiStart);
		if (WiEnd == -1) WiEnd = WiAllCookies.length;
		var WiLoadPage = unescape(WiAllCookies.substring(WiStart,WiEnd)); 
		document.cookie="WiLoadPage=; path=/";
		if(WiLoadPage.indexOf(".htm") > 0)	
		self.location.replace(WiLoadPage);}}

