<html>
<head>
	<title>Memento Login</title>
	<link rel="StyleSheet" href="styles/default.css" type="text/css">
</head>
<body bgcolor="#ffffff" text="#000000" link="#004433" alink="#004433" vlink="#004433">
<center>
	<br>
	<br>
	<br>
	<div align='center'><b>User Login</b></div>
	<br>

	<form action='index.php' method='post'>
	<table border="0">
		<?php global $username, $emailsuccess; if (isset($username)) { ?>
		<tr>
			<td align='center'>
				<?php if (!$emailsuccess) { ?>
				<font color='#ff0000'>
					<b>Invalid login and/or password</b>
				</font>
				<?php } else { ?>
				<font color='#0000ff'>
					<b>Your password has been mailed to you</b>
				</font>
				<?php } ?>
			</td>
		</tr>
		<?php } ?>
		<tr>
			<td><?php echo EMAIL_IS_LOGIN ? 'Email' : 'Login' ?></td>
		</tr>
		<tr>
			<td><input size="30" name='username' value='<?php if (isset($_sv["uname"])) print $_sv["uname"] ?>'></td>
		</tr>
		<tr>
			<td>Password:</td>
		</tr>
		<tr>
			<td><input size="30" type='password' name='password'></td>
		</tr>
		<tr>
			<td align="right">
				<input type="submit" value="Go">
				<input type="submit" name="sendpass" value="Email my password">
				<input type="hidden" name="dologin" value="1">
			</td>
		</tr>
		<?php if (!NEW_ACCOUNTS_DISABLED) { ?>
		<tr>
			<td align="center">
				<hr size="1" color="#000000" width="140">
				<br>
				<br>
				<a href="newaccount.php">Open a new account</a>
			</td>
		</tr>
		<?php } ?>
	</table>
	</form>
</center>
</body>
<script language="JavaScript">
<!--
  if (document.forms[0][0].value != '') {
      document.forms[0][1].focus();
  } else {
      document.forms[0][0].focus();
  }
// -->
</script>
</html>
