<?php
$Admin_Username=mysql_escape_string($_POST['Admin_Username']);
$Admin_Password=mysql_escape_string($_POST['Admin_Password']);
//Data base check here
if ($Admin_Password == 'XXX' AND $Admin_Username == 'XXX')
{
session_start();
$_SESSION['123']='123';
// need to close the colorbox - I know this is not right
parent.jQuery.fn.colorbox.close(); return false;
//then redirect parent to index.phph with the session starting
header('Location: index.php');
}
//else redirect userback to loginform
else header('Location: login.php');
?>
|