<?

// Get Current Language From URL
$current_url = explode('/',$_SERVER['REQUEST_URI']);
$new_login_language = $current_url[1];

// Define Permitted Language
$permitted_language = array("en","kr","sp","ge","fr");

// Check Invalid Value
if(!in_array($new_login_language,$permitted_language)) {
	$new_login_language = "en";
}

// Set Cookie
setcookie("lgnas_language", $new_login_language, time()+31536000, "/");
?>


<!--
// LGE NAS-SSS 
// By park94
// Language select
-->



<html>
<head>
<title>:::::::: Welcome to LG Electronics ::::::::</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script language='javascript' src='../js/debug.js' charset='utf-8' type='text/javascript'></script>		<!--debugging setting-->
<script language='javascript' src='../js/jslb_ajax.js.php' charset='utf-8' type='text/javascript'></script>	<!--ajax lib-->
<script language='javascript' charset='utf-8' type='text/javascript'>
	gPage='login';		// set page name for language setting
</script>
<script language="javascript" src="../css/embed.js" type='text/javascript'></script>
<script language=javascript src="../css/lg.js" type='text/javascript'></script>
<script language='javascript' src='../css/flash.js' type='text/javascript'></script>

<link href="../css/styles.css" rel="stylesheet" type="text/css">
<link href="../css/css.css" rel="stylesheet" type="text/css">
<SCRIPT language=javascript src="../css/selectBox.js" type='text/javascript'></SCRIPT>

<script language="javascript1.2" src="../js/common.js.php" charset="utf-8" type='text/javascript'></script>
<script language="javascript1.2" src="../js/login.js.php" charset="utf-8" type='text/javascript'></script>

<script language='javascript' type="text/javascript">
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
<style type="text/css">
<!--
.style1 {
	color: #6E6F71;
	font-size: 10px;
}
-->
</style>

</head>

<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="all_table">
  <tr>
    <td width="100%" height="950" align="center" valign="top" background="../images/login/bg.gif" style="padding:230 0 0 0px">
    <table width="570" border="0" cellspacing="0" cellpadding="0">
    			<tr>
    				<td ><img src="../images/login/login_logo.gif" /></td>
        		<td align="right">
        		
        			<!-- Language select -->		
    				
    				  
		    				  <table cellspacing="0px" cellpadding="0px">
		    				  	<tr>
		    				  		<td><a href="../../ge/login/login.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('txt_ge','','../images/login/txt_ge_over',1)"><img src="../images/login/txt_ge.gif" border="0" title="Deutsch" name="txt_ge"></a></td>
		    				  		<td><a href="../../en/login/login.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('txt_en','','../images/login/txt_en_over',1)" ><img src="../images/login/txt_en.gif" border="0" title="English" name="txt_en"></a></td>
		    				  		<td><a href="../../sp/login/login.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('txt_sp','','../images/login/txt_sp_over',1)"><img src="../images/login/txt_sp.gif" border="0" title="Español" name="txt_sp"></a></td>
		    				  		
				    				  <td><a href="../../fr/login/login.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('txt_fr','','../images/login/txt_fr_over',1)"><img src="../images/login/txt_fr.gif" border="0" title="Français" name="txt_fr"></a></td>
				    					<td><a href="../../kr/login/login.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('txt_kr','','../images/login/txt_kr_over',1)"><img src="../images/login/txt_kr.gif" border="0" title="한국어" name="txt_kr"></a></td>
				    				</tr>
				    			</table>
    				</td>
    			</tr>
    	</table>
    		
    	<table width="570" height="367px" border="0" cellspacing="0" cellpadding="0" style="background:url('../images/login/form_bg.gif'); background-repeat:no-repeat;">
    		<tr height="275px"><td>
    					<table width="340px" height="150px" border="0" style="margin:20px 0 0 145px;">
    						<tr height="80px">
    								<td colspan="2"><img src="../images/login/txt_login.gif"></td>
    								<td rowspan="3" width="80px" style="padding-top:65px"><img src="../images/login/btn_login.gif"  onClick="check_info1();" style="cursor:pointer;"/></td>
    						</tr>
    						<tr height="30px">
    								<td><img src="../images/login/txt_id.gif"></td>
    								<td width="140px"><input onblur="FormCheck('idInId');" name="textfield" type="text" class="inputtext_04" id="idInId" value="" size="18" maxlength="12"></td>
    									
    						</tr>	
    						<tr height="40px">
    								<td><img src="../images/login/txt_pw.gif"></td>
    								<td><input onfocus="this.value='';" onblur="FormCheck('idInPw');" onkeydown="return processOnEnter(event);" name="textfield2" type="password" class="inputtext_04" id="idInPw" value="" size="18" maxlength="20"></td>
    						</tr>
    					</table>

    			</td>
    		</tr>
    		<tr><td><img src="../images/login/form_shadow.gif" width="570" height="92" /></td></tr>
   		 </table>
 
    </td>
  </tr>
</table>

<script language='javascript' charset='utf-8' type='text/javascript'>
init();
function init()
{
	gPage='login';
	// to do 
	document.getElementById('idInId').focus();
}
</script>

</body>
</html>

