tutaj kod logowania:
<?php include("includes/header.php"); include("includes/messages.php"); ?> <?php if($Submit == "Submit") { $st = "select * from StatMember where username = '$username' and password = '$password' and account_status = 'P'"; { $sessionSiteId = $row['userid']; $sessionUser = $username; } else { $msg = $M_Usernamenotfound; } } ?> <script language="Javascript"> function validate() { with(document.frm) { if(username.value == "") { alert("Please enter username"); username.focus(); return false; } if(password.value == "") { alert("Please enter password"); password.focus(); return false; } } } </SCRIPT> <FORM name=frm method="post" action="login.php" onSubmit="return validate();"> <TABLE width="300" border="0" cellspacing="1" cellpadding="2" align="center"> <TR> <TD colspan="2"> <DIV align="center"> <B><FONT face="Arial, Helvetica, sans-serif" size="2">Members Login</B> </DIV> </TD> </TR> <TR> <TD colspan="2"> <DIV align="center"> <?php if($msg != "") { } ?> </DIV> </TD> </TR> <TR> <TD width="100"> <DIV align="right"><FONT face="Arial, Helvetica, sans-serif" size="2">Username:</DIV> </TD> <TD width="200"> <INPUT type="text" size=12 name="username"> </TD> </TR> <TR> <TD width="100"> <DIV align="right"><FONT face="Arial, Helvetica, sans-serif" size="2">Password:</DIV> </TD> <TD width="200"> <INPUT type="password" size=12 name="password"> </TD> </TR> <TR> <TD colspan="2"> <DIV align="center"> <INPUT type="submit" name="Submit" value="Submit" class="button"> <INPUT type="reset" name="Reset" value="Reset" class="button"> </DIV> </TD> </TR> </TABLE> </FORM> <?php include("includes/footer.php"); ?>