|Join Nairaland / LOGIN! / Trending / Recent / New|
Stats: 2,509,446 members, 5,718,280 topics. Date: Friday, 10 July 2020 at 12:39 PM
|Login Applicatins by steepe(m): 2:11pm On Oct 25, 2007|
Sorry guys, its me again! I'm just learning php and seem to have problems with creating a login application using sessions. Can anybody help?
|Re: Login Applicatins by smartsoft(m): 2:54pm On Oct 25, 2007|
paste the code you have
|Re: Login Applicatins by steepe(m): 3:13pm On Oct 25, 2007|
$username = $_POST['username'];
$password = $_POST['password'];
$conn = mysql_pconnect("localhost","root",""
//$sql = ;
//echo "sql = $sql";
$result = mysql_query("SELECT * FROM userauth WHERE username = '$username' AND pswd = md5('$password')"
$rows = mysql_fetch_assoc($result);
$_SESSION['username'] = $rows['username'];
echo "do_login: name =".$_SESSION['username'];
$page = $_GET['p'];
$page = "member.php";
//echo "page ".$page;
|Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health |
religion celebs tv-movies music-radio literature webmasters programming techmarket
Nairaland - Copyright © 2005 - 2020 Oluwaseun Osewa. All rights reserved. See How To Advertise. 22