<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11">
<html>
<head>
	<title>%%LNG_AdminControlPanelTitle%%</title>
	<meta http-equiv="Content-Type" content="text/html; charset=%%GLOBAL_charset%%" />
	<style type="text/css">
		@import url("styles/styles_admin.css");
	</style>
	<!--[if IE]>
	<style type="text/css">
		@import url("Styles/ie.css");
	</style>
	<![endif]-->
	<script type="text/javascript">
		var kbpath = '%%GLOBAL_pathToKB%%';
	</script>
	<script type="text/javascript" src="../javascript/jquery.js"></script>
	<script type="text/javascript" src="includes/general.js"></script>
	<script type="text/javascript" src="includes/menudrop.js"></script>
	<script type="text/javascript" src="includes/datepicker.js"></script>

	<script type="text/javascript" src="../javascript/iselector.js"></script>
	<script type="text/javascript" src="../javascript/thickbox.js"></script>
	<link rel="icon" href="%%GLOBAL_faviconLink%%" />
	<link rel="stylesheet" href="styles/thickbox.css" type="text/css" media="screen" />
</head>

<body>
	<form action="index.php?ToDo=nojs" method="post" name="frmLogin" id="frmLogin">
	<div id="box">
		<table><tr><td style="border:solid 2px #DDD; padding:20px; background-color:#FFF; width:320px;">
		<table>
		  <tr>
			<td class="Heading1">
				<!-- Removing or editing this Image Tag will violate your license agreement with Interspire -->
				<img src="index.php?ToDo=drawLogo"  alt="%%LNG_CompanyLogoText%%"/>
			</td>
		  </tr>
		  <tr>
			<td style="padding:10px 0px 5px 0px">%%GLOBAL_Message%%</td>
		  </tr>
		  <tr>
			<td>
				<table>
				<tr>
				  <td nowrap="nowrap" style="padding:0px 10px 0px 10px">%%LNG_UsernameLabel%%</td>
				  <td>
					<input type="text" name="username" id="username" class="Field150" value="%%GLOBAL_Username%%">
				  </td>
				</tr>
				<tr>
				  <td nowrap="nowrap" style="padding:0px 10px 0px 10px">%%LNG_PasswordLabel%%</td>
				  <td>
					<input type="password" name="password" id="password" class="Field150" value="%%GLOBAL_Password%%">
				  </td>
				</tr>
				<tr>
				  <td nowrap>&nbsp;</td>
				  <td>&nbsp;<input type="checkbox" name="remember" id="remember" value="1" style="margin-left:-0px" %%GLOBAL_RememberMe%%> <label for="remember">%%LNG_RememberMe%%</label>
				  </td>
				</tr>
				  <tr>
					<td>&nbsp;</td>
					<td>
					  <input type="submit" name="SubmitButton" value="%%LNG_Login%%" class="FormButton">
					  &nbsp;&nbsp;%%LNG_ForgotPassLink%%
					</td>
				  </tr>
				  <tr><td class="Gap"></td></tr>
			  </table>
			</td>
		  </tr>
		</table>
		</td></tr>

			<tr>
				<td>
					<div class="PageFooter" style="padding: 10px 10px 10px 0px; margin-bottom: 20px; text-align: center;">
						<!-- Removing or editing this "Powered by" link will violate your license agreement with Interspire -->
						%%LNG_PagePoweredByShort%%
					</div>
				</td>
			</tr>

		</table>
	</div>

	</form>

	<script>

		$('#frmLogin').submit(function() {
			var f = document.frmLogin;

			if(f.username.value == '')
			{
				alert('%%LNG_NoUsername%%');
				f.username.focus();
				f.username.select();
				return false;
			}

			if(f.password.value == '')
			{
				alert('%%LNG_NoPassword%%');
				f.password.focus();
				f.password.select();
				return false;
			}

			// Everything is OK
			f.action = 'index.php?ToDo=processLogin';
			return true;
		});

		function sizeBox() {
			var w = $(window).width();
			var h = $(window).height();
			$('#box').css('position', 'absolute');
			$('#box').css('top', h/2-($('#box').height()/2)-50);
			$('#box').css('left', w/2-($('#box').width()/2));
		}

		$(document).ready(function() {
			sizeBox();
			$('#username').focus();
		});

		$(window).resize(function() {
			//sizeBox();
		});

	</script>

</body>
</html>