/*****************************************************************************************************/
/*                                                                                                   */
/*                                      'MY ACCOUNT' CONTROL PANEL                                   */          
/*                                                                                                   */
/*****************************************************************************************************/

var MyAccountObject = new Object();


function initMyAccountPanel(){
	
	if (document.forms['myaccount_form'] == null){
		return;	
	}
	
	MyAccountObject.info = new MYACCOUNT_GINFO(this);
	MyAccountObject.initInfo = init_MyAccountGeneralInfo;
	MyAccountObject.initInfo();
}


/*****************************************************************************************************/
/*                                                                                                   */
/*                           FUNCTION INITIALIZE GENERAL INFORMATION                                */          
/*                                                                                                   */
/*****************************************************************************************************/
function init_MyAccountGeneralInfo(){
	this.info.init();
	this.info.initCreate();
}


/*****************************************************************************************************/
/*                                                                                                   */
/*                                         FUNCTION VALIDATION                                       */          
/*                                                                                                   */
/*****************************************************************************************************/
function validateMyAccount(){
	if (MyAccountObject != null){
		MyAccountObject.info.initServerValidate();
	}
}


var sec;
function redirectMyAccount(){
	if (sec == 0){
		document.location.href = "my_account.php";
	}
	document.getElementById("seconds").innerHTML = sec;
	if (sec > 0){
		sec--;
	}
	setTimeout(redirectMyAccount,1000);
}