<?php    
    if(isset($_POST['ftusername'])) {
                
        $username_stg=$_REQUEST['ftusername'];
        $password_stg=$_REQUEST['ftpassword'];
        $fnid=RetRstField("SELECT fnid FROM tluser WHERE ftusername = '{$_SESSION['username']}'");
        
        if($username_stg=="setting" && $password_stg=="admin") {
                echo "<script> 
                      window.location='setting.php?form=system_setting&mode=edit&id={$fnid}';
                      </script>";
                exit;
        }
        else {
             echo "<script>
                      alert('Login Gagal ...');                     
                    </script>";
        }
    }
?>

<html dir="ltr" xml:lang="en-gb" xmlns="http://www.w3.org/1999/xhtml" lang="en-gb">
<head>


  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Login</title>
  

<link rel="stylesheet" href="login/system.css" type="text/css">
<link href="login/login.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" type="text/css" href="login/rounded.css">

<script language="javascript" type="text/javascript">
	function setFocus() {
		document.login.username.select();
		document.login.username.focus();
	}
</script>
</head><body onload="javascript:setFocus()">
	<div id="border-top" class="h_green">
		<div>
			<div>
				<span class="title"></span>
			</div>
		</div>
	</div>
	<div id="content-box">
		<div class="padding">
			<div id="element-box" class="login">
				<div class="t">
					<div class="t">
						<div class="t"></div>
					</div>
				</div>
				<div class="m">

					<h1>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Login</h1>
					
							<div id="section-box">
			<div class="t">
				<div class="t">
					<div class="t"></div>
		 		</div>
	 		</div>
			<div class="m">
				<form action="" method="post" name="login" id="form-login" style="clear: both;">
	<p id="form-login-username">
		<label for="modlgn_username">Username</label>
		<input name="ftusername" id="modlgn_username" class="inputbox" size="15" type="text">
	</p>

	<p id="form-login-password">
		<label for="modlgn_passwd">Password</label>
		<input name="ftpassword" id="modlgn_passwd" class="inputbox" size="15" type="password">
	</p>
		
	<div class="button_holder">
	<div class="button1">
		<div class="next">
			<a onclick="login.submit();">
				Login</a>

		</div>
	</div>
	</div>
	<div class="clr"></div>
	<input style="border: 0pt none ; margin: 0pt; padding: 0pt; width: 0px; height: 0px;" value="Login" type="submit">
	<input name="option" value="com_login" type="hidden">
	<input name="task" value="login" type="hidden">
	<input name="3e44eda6a3c3a1755ab75318f9b49db9" value="1" type="hidden"></form>
				<div class="clr"></div>
			</div>
			<div class="b">
				<div class="b">
		 			<div class="b"></div>
				</div>
			</div>
		</div>
		
					<p>Silahkan Login untuk masuk ke System Setting</p>
					<p>
						<a href=""></a>
					</p>
					<div id="lock"></div>
					<div class="clr"></div>
				</div>
				<div class="b">
					<div class="b">
						<div class="b"></div>
					</div>
				</div>
			</div>
			<noscript>
				Warning! JavaScript must be enabled for proper operation of the Administrator back-end.			</noscript>
			<div class="clr"></div>
		</div>
	</div>
	<div id="border-bottom"><div><div></div></div>
</div>

<div id="footer">
	<p class="copyright"></p>
</div>
</body></html>