
// loading images for - "How To Earn G-cents"
sell_out_Img = new Image()
sell_out_Img.src = 'images/community/sell_fashion_out.gif';
sell_over_Img = new Image()
sell_over_Img.src = 'images/community/sell_fashion_over.gif';

update_out_Img = new Image()
update_out_Img.src = 'images/community/update_your_out.gif';
update_over_Img = new Image()
update_over_Img.src = 'images/community/update_your_over.gif';

bring_out_Img = new Image()
bring_out_Img.src = 'images/community/bring_your_out.gif';
bring_over_Img = new Image()
bring_over_Img.src = 'images/community/bring_your_over.gif';

invite_out_Img = new Image()
invite_out_Img.src = 'images/community/invite_shoppers_out.gif';
invite_over_Img = new Image()
invite_over_Img.src = 'images/community/invite_shoppers_over.gif';

play_out_Img = new Image()
play_out_Img.src = 'images/community/play_the_out.gif';
play_over_Img = new Image()
play_over_Img.src = 'images/community/play_the_over.gif';


function SetMyPrices(mode,uid)
{
/*
	if(mode == null)
	{
		mode = 'editor'
	}
	if(uid == null)
	{
		uid = ''
	}
	SetMyPricesWinHandler = window.open('http://www.girlsense.com/premium/eBoutiques/priceList.pl?mode=' + mode + '&uid=' + uid,'SetMyPricesWin','scrollbars=no,toolbar=no,resizable=yes,status=no,left=10,top=10,width=660,height=530');	
*/	
	SetMyPricesWinHandler = window.open('http://www.girlsense.com/premium/eBoutiques/viewer.pl?action=fashionsTab','SetMyPricesWin','scrollbars=no,toolbar=no,resizable=yes,status=no,left=10,top=10,width=1024,height=600');	
}

//alert("hi");
function ResizeToInner(innerWidth, innerHeight)
{
	//alert("ResizeToInner activated");
	var frameWidth,frameHeight;
	if (self.innerHeight) // all except Explorer
	{
		frameWidth = self.innerWidth;
		frameHeight = self.innerHeight;
	}
	else if (document.documentElement && document.documentElement.clientHeight) // Explorer 6 Strict Mode
	{
		frameWidth = document.documentElement.clientWidth;
		frameHeight = document.documentElement.clientHeight;
	}
	else if (document.body) // other Explorers
	{
		frameWidth = document.body.clientWidth;
		frameHeight = document.body.clientHeight;
	}

	var innerWidth = ( innerWidth!=null ? innerWidth : frameWidth );
	var innerHeight = ( innerHeight!=null ? innerHeight : frameHeight );

	difWidth = 0 + innerWidth - frameWidth;
	difHeight = 0 + innerHeight - frameHeight;

	/*
	alert("frameWidth = " + frameWidth + "\n" + "frameHeight = " + frameHeight);
	alert("difWidth = " + difWidth + "\n" + "difHeight = " + difHeight);
	*/

	if (difWidth != 0 )
	{
		window.resizeBy(difWidth,0);
	}
	if (difHeight != 0)
	{
		window.resizeBy(0,difHeight);
	}

	// scroll down
	window.scrollBy(0,120);
}

///////////// Drop down menu procedure ////////////////////////////////////////////
var last_div;

// This function is doing the Drop down divs 

function drop_down(whichdiv)
{
	current_div = document.getElementById(whichdiv); //Get element of the current div
		if ((current_div == last_div) && (current_div.style.display == "block"))
			{
			current_div.style.display = "none";
			}	
		else
		{
			last_div.style.display = "none";
			current_div.style.display = "block";  // displayes the current_div.
			last_div = current_div; //The current_div is now the last_div
		}
}

///////////////////////// Links functions /////////////


// This function opens the MAIN Send2Friend (from GS homepage) -  invite your friends for 100 G-cents
function Send2FriendGS()
{
	var activity = 'generic';
    window.open('http://www.girlsense.com/premium/tools/send2friend/index.pl?activity=' + activity,'send2friendWin','scrollbars=auto,toolbar=no,menubar=no,resizable,left=10,top=10,width=403,height=498');
}
//This function opens the Banner maker
function Go2BannerMaker()
{
	
	var fromLeft = window.screenLeft + 40;
	var fromTop = window.screenTop;
	theLink = '/premium/bannerMaker/';
	activityWinHandler = window.open(theLink,'BannerMakerWin','scrollbars=yes,resizable=yes,left='+fromLeft+',top='+fromTop+',width=800,height=545');
}
//This function opens the GSBoard
function Go2GSBoard()
{
	GSBoardWinHandler = window.open('http://www.girlsense.com/premium/GSBoard/','GSBoardWin','scrollbars=no,toolbar=no,resizable=yes,status=no,left=10,top=10,width=803,height=599');	
	
}
//This function opens the FDS
function Go2FDS()
{
	//FDSWinHandler = window.open('http://www.girlsense.com/premium/fashionDesign/index.pl?mode=gs','FDSWin','scrollbars=no,toolbar=no,resizable=yes,status=yes,left=10,top=10'); //width=790,height=490		
	FDSWinHandler = window.open('http://www.girlsense.com/premium/eBoutiques/viewer.pl?action=studioTab','FDSWin','scrollbars=no,toolbar=no,resizable=yes,status=yes,left=10,top=10,width=1024,height=600'); 		
}

function Go2Fashionave()
{
	FashionAveWin = window.open('http://www.girlsense.com/premium/eboutiques','FDSWin','scrollbars=yes,toolbar=yes,resizable=yes,status=yes,left=10,top=10,fullscreen=yes');		 //width=790,height=490
}