<?php 
	  require_once "./includes/common.php";
	  require_once $config['SiteClassPath']."class.Staff.php";
	// require_once $config['SiteClassPath']."class.Login.php";
	

	
		  $objStaff	= new Staff();
		  //$objStaff->chkStaffLogin($_POST);
		// $objLogin	= new Login();
	     if(isset($_POST['hdAction']))
	     {
			 
	        $objStaff ->chkStaffLogin($objArray);
			//$objSmarty->assign('ErrorMessage', 'Invalid Mobile Number or Password !');
			if(isset($_SESSION['UserName']))
			{ 	
				Redirect("profile.php");
			}
			else
			{
				Redirect("login.php");
			}
         }
		
		 if($_GET['message']=="success")
         {
             $objSmarty->assign('SuccessMessage', 'Your Password has been Updated, Please Login.');
         } 
             
       
		$objSmarty->assign('IncludeTpl', 'login.tpl');
		$objSmarty->assign('OverallSiteTitle', $config['SiteTitle'].'- Easwari Lending  Library');
		$objSmarty->assign('author','suresh@adroitsolutionz.com');
		$objSmarty->assign('document-state','dynamic');
		$objSmarty->assign('address',$config['SiteGlobalPath']); 
	   
		/*Display page*/
		$objSmarty->assign('HeaderTpl', 'header.tpl');
		$objSmarty->assign('FooterTpl', 'footer.tpl');
		$objSmarty->display('pagetemplate.tpl');
			
 ?>