﻿Authentication = {}

//jQuery로 변경이후 사용하지 않음
Authentication.ShowLoginArea = function(LoginPanelID, focusCtl) {
    if ($get(LoginPanelID).style.display == "none") {
        if (focusCtl) $get(focusCtl).focus(); ;
    } else
        $get(LoginPanelID).style.display = "none";
}

//jQuery로 변경이후 사용하지 않음
Authentication.EnterForLogin = function(LoginBtn)
{	
	if(event.keyCode == 13) 
	{
		$get(LoginBtn).click();	
		self.focus();
		return;
	}	
	else 
		return false;	
}

Authentication.Logout = function()
{
	location.href = "/Users/Logout.aspx";
}

Authentication.UserOut = function()
{
	if(confirm("정말로 탈퇴하시겠습니까?\n\n탈퇴와 동시에 사용자님의 모든 개인정보는 삭제됩니다"))
	{
		location.href="/MyPage/EditUserOut.aspx";
	}
	else
	{
		return;
	}
}

                                
//function ReplaceAll(strOriginal, strFind, strChange){
//    var position, length;
//    position = strOriginal.indexOf(strFind);  
//    
//    while (position != -1){
//      strOriginal = strOriginal.replace(strFind, strChange);
//      position    = strOriginal.indexOf(strFind);
//    }
//    
//    return strOriginal;
//}