Closed Sqt123 closed 8 years ago
Post this code in auth.php check if its return any id or not.
<?php require_once('includes/load.php'); ?> <?php $req_fields = array('username','password' ); validate_fields($req_fields); $username = remove_junk($_POST['username']); $password = remove_junk($_POST['password']);
if(empty($errors)){ $user_id = authenticate($username, $password); var_dump($user_id); // if($user_id){ // $session->login($user_id); // $session->msg("s", "Wel Come."); // redirect('home.php',false); // } else { // // $session->msg("d", "Sorry Username/Password incorrect."); // redirect('index.php',false); // }
} else { $session->msg("d", $errors); redirect('index.php',false); }
?>
It returns string(1) "0"
can you login as a admin?
Yes as admin I can login
On 17/09/2015 21:16, Siamon Hasan wrote:
can you login as a admin?
— Reply to this email directly or view it on GitHub https://github.com/siamon123/warehouse-inventory-system/issues/5#issuecomment-141171677.
its mean either username or password is wrong. function should return either user id or false.
thanks Siamon123. its work for me, just change in database.php
add require_once("../folder/includes/config.php") for xampp
Yea some how XAMPP new version has include bug. i am glade you fix it on yourself. give me Feedback on Facebook. thank you.
Hi,
There is some nice stuff I've just found, I thought you might be interested, just take a look http://lessandra.ajlconsultingltd.com/e3wcr/90
Bests, d.reingoldas
Hello, I have a problem, I have created few users, and somehow they cannot login to the system Could you help me fix this problem ?
Thanks.