Location: PHPKode > projects > Helpdesk Solutions > helpdesk/login.php
<?
include($DOCUMENT_ROOT.'/helpdesk/include/database.php');
include($DOCUMENT_ROOT.'/helpdesk/include/new_user.php');

session_start();
//echo "<br>User ID is: $user_id";

$head = "Login";
$bttm_menu = " &nbsp;&nbsp;<a class=bttm_menu href='/helpdesk/logout.php'>Log Out</a>&nbsp;&nbsp;|
";

user_logout();

if ($err_msg) {
	retrieve_msg($err_msg,$conn);
}


$bottom = "
<em class=redtext>$error_msg</em>
<br>

<center><h1>=Welcome to the Helpdesk=</h1>
	
Please enter your username and password:<BR><BR>
<table border=0>
<form method=post action=$PHP_SELF>


<tr><td class=redtext><b>Username: </b><td><input type=text name=username size=15 maxlength=25>
<tr><td class=redtext><b>Password: </b><td><input type=password name=password size=15 maxlength=25>
</table>
<br>
<input type=submit name=submit value='Log In'>
</form>

<table>
<tr><td>You may sign in using the following username and password:
<tr><td align=center><b>User:</b> mickey
<tr><td align=center><b>Pass:</b> mouse

</center>

";

if ($submit) {
	user_login($username,$password,$conn);
} else {
	//$bottom = $bottom2;
}
if (($per_id == "1") && ($valid == 'yes')) {
	//echo "<br>Would Move; Id is: $user_id";
	header("Location: /helpdesk/scripts/main_adminmenu.php");
	exit;
} else if ($valid == 'yes') {
	$warning .= "<tr><td class=redtext>** You are not an administrator";
}


include($DOCUMENT_ROOT.'/helpdesk/include/template.inc.php');
?>
Return current item: Helpdesk Solutions