topflight Posted February 7, 2009 Share Posted February 7, 2009 I Have A login Script that works just fine. However my Login Script is on the side of my website so when you login the login box expands and you will get the special user options. Well the problem I am having is that if you login on any page the (index,contactus,historty etc....) you can login successfully however when you go to another page the login box turns into the login form with the basic ID and Password form. I want to be like if you are loged in no matter what page you go to the login box will still show the login options. Currently in my situation it doesn't you have to keep logging in. I am using sessions and the sessions are registering because I have certain pages that only user can see with registered sessions. The following is my code <?php if(isset($_POST['user'])) { //Include Config File For DB info.. include 'db.php'; //Connect TO The MySQL Server $connect = mysql_connect($db_host,$db_username,$db_password) or die("MySQL Said:".mysql_error()); $database = mysql_select_db($db_database,$connect) or die("MySQl Said:".mysql_error()); $login = mysql_real_escape_string($_POST['user']); $pwd = mysql_real_escape_string($_POST['pwd']); $link = mysql_query("SELECT * FROM `pilots` where login='$login' and pwd='$pwd'") or die("MySQL Said:".mysql_error()); $count = mysql_num_rows($link); $data = mysql_fetch_assoc($link); $lname = $data["lname"]; $hub = $data["hub"]; $pwd = $data["pwd"]; $fname = $data["fname"]; if($count == 1) { if($data['status'] == 0) { echo '<center>Your Account Is Not Active.</center>'; } else { if($data['status'] == 2) { echo '<center><FONT COLOR =ff001b>Your Account Has Been Suspended.</center></FONT COLOR>';?> <center><a href="logout.php">Log Out</a></br></center> <?php } else { if($data['status'] == 3) { echo '<center>You Are Currently On L.O.A</center>';?> <a href="rfileloa.php?login=<? echo "{$data["login"]}"?>">Return From L.O.A</a></br><?php } else { setcookie("login",$login); setcookie("lname",$lname); setcookie("hub",$hub); setcookie("pwd",$pwd); setcookie("fname",$fname);?> <body link="#0066FF" vlink="#0066FF" alink="#0066FF"> <center> <h7><i><b>Pilots Panel</b></i></h7></br> <a href="filepirep.php?lname=<? echo "{$data["lname"]}"?>">File Pirep</a></br> <a href="fileloa.php?login=<? echo "{$data["login"]}"?>">File LOA</a></br> <a href="sigs.php">Signatures</a></br> <A HREF="profile.php?login=<? echo "{$data["login"]}"?> ">My Profile</a></br> <a href="editp.php?login=<? echo "{$data["login"]}"?>">Edit My Profile</a></br> <a href="#">Events</a></br> <a href="roster.php">VIew Roster</a></br> <a href="#"><font color="#FF0000">Resignation Form</font Color></br> <a href="logout.php">Log Out</a></br> <br> <h7><i><b>Pilots Tools</b></i></h7></br> <a href="http://www.fspassengers.com/"> FS Passengers</a></br> </center> <?php if($data['hm'] == 1) {?> <center> <h7><i><b>Hub Manager Panel</b></i></h7></br> <a href="edithub.php?hub=<?php echo $data['hub']; ?>">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> </center> <?php } if($data['fm'] == 1) {?> <center> <h7><i><b>Fleet Manager Panel</b></i></h7></br> <a href="addaircraft.php">Add Aircraft</a></br> <a href="manageaircraft.php">Manage Aircraft</a> </center> <?php } if($data['ed'] == 1) {?> <center> <h7><i><b>Events Director Panel</b></i></h7></br> <a href="addevent.php">Add Event</a></br> <a href="manageevents.php">Manage Events</a></br> <a href="postnews.php">Post News</a></br> </center> <?php } if($data['hr'] == 1) { ?> <center> <h7><i><b>Human Rescources Panel</b></i></h7></br> <a href="newpilots.php">New Pilots</a></br> <a href="editpilots.php">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <?php } if($data['bm'] == 1) {?> <center> <h7><i><b>Executive Staff Panel</b></i></h7></br> <a href="edithub.php?hub=<?php echo $data['hub']; ?>">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> <a href="addaircraft.php">Add Aircraft</a></br> <a href="addstaffmember.php">Grant Staff Acesses</a></br> <a href="revokestaffmember.php">Revoke Staff Acesses</a></br> <a href="manageaircraft.php">Manage Aircraft</a></br> <a href="addevents.php">Add Event</a></br> <a href="manageevents.php">Manage Events</a></br> <a href="postnews.php">Post News</a></br> <a href="pilotrec.php">Pilot Records</a></br> <a href="newpilots.php?staffid=<? echo "{$data["login"]}"?>">New Pilots</a></br> <a href="editpilots.php">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <?php } } } } } else {?> <script>javascript:alert("Log In Failed!")</script> <?php echo '<center><FONT COLOR =ff001b> Your <i>Pilot ID And/Or Password</i> is wrong!</center></FONT COLOR>';?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><input type="submit" name="login" value="Login"></td> </tr> </table> <? }?> <?php } else {?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><input type="submit" name="login" value="Login"></td> </tr> </table> <?php } ?> Once again my login information is on the right side of my site and when you click login and if everything is correct the box expands and shows you the user options like it is suppose to but if you go to another page on the site the login box goes back to the login form and I want it to have it set up so that the login content will still show unless you hit logout. Help is really appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/ Share on other sites More sharing options...
Errant_Shadow Posted February 7, 2009 Share Posted February 7, 2009 with your cookies, try adding "/" after the variable. I was having a problem with accessing cookies that I set, but when I added that I was able to access them. setcookie("login",$login,"/"); setcookie("lname",$lname,"/"); setcookie("hub",$hub,"/"); setcookie("pwd",$pwd,"/"); setcookie("fname",$fname,"/"); Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-756669 Share on other sites More sharing options...
topflight Posted February 7, 2009 Author Share Posted February 7, 2009 However I am using sessions Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-756863 Share on other sites More sharing options...
camdenite Posted February 7, 2009 Share Posted February 7, 2009 Not that this is what you are asking for but why do you keep opening and closing php tags? Instead of: <body link="#0066FF" vlink="#0066FF" alink="#0066FF"> <center> <h7><i><b>Pilots Panel</b></i></h7></br> <a href="filepirep.php?lname=<? echo "{$data["lname"]}"?>">File Pirep</a></br> you could do echo '<body link="#0066FF" vlink="#0066FF" alink="#0066FF"> <center> <h7><i><b>Pilots Panel</b></i></h7></br> <a href="filepirep.php?lname=<' . data['lname'] . '>File Pirep</a></br>' Cheers Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-756876 Share on other sites More sharing options...
camdenite Posted February 7, 2009 Share Posted February 7, 2009 Ok here goes - I'm not brilliant at this but: <?php // Create a login/logout link. if ( (isset($_SEESION['login'])) $$ (!strpos($_SERVER['PHP_SELF'], 'logout.php')) ) { echo '<a href="logout.php title="Logout">Logout</a>'; } else { echo '<a href="login.php" title="login">login</a>'; } ?> Hope this helps - appologies for posting before I finished. I couldn't work out how you login but I'm sure you can adapt the script. Taken from PHP And MySQL for Dynamc Websites by Larry Ullman. Cheers, Colin Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-756884 Share on other sites More sharing options...
BloodyMind Posted February 7, 2009 Share Posted February 7, 2009 With the way you are validating the user, you are using server resources so much anyways, what you should do: validate once in the login page and set sessions vars instead of cookies like this way sessions_start(); $_SESSION['login']= $login; $_SESSION['is_logged_in'] = true; .....etc with that session variable $_SESSION['is_logged_in'] you can validate if he is logged in or not and also display the box of his control panel by using an if statement... I also recommend you to use md5() or sha1() functions to encrypt user password, search the manual for it. hope my reply was useful Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-757056 Share on other sites More sharing options...
topflight Posted February 8, 2009 Author Share Posted February 8, 2009 wi With the way you are validating the user, you are using server resources so much anyways, what you should do: validate once in the login page and set sessions vars instead of cookies like this way sessions_start(); $_SESSION['login']= $login; $_SESSION['is_logged_in'] = true; .....etc with that session variable $_SESSION['is_logged_in'] you can validate if he is logged in or not and also display the box of his control panel by using an if statement... I also recommend you to use md5() or sha1() functions to encrypt user password, search the manual for it. hope my reply was useful Will I put that at the top of the login.php page or bottom? And tried something similar to that but my login script got messed up a little bit. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-757278 Share on other sites More sharing options...
topflight Posted February 8, 2009 Author Share Posted February 8, 2009 This is what my login code looks like now. <?php session_start(); ?> <?php if(isset($_POST['user'])) { //Include Config File For DB info.. include 'db.php'; //Connect TO The MySQL Server $connect = mysql_connect($db_host,$db_username,$db_password) or die("MySQL Said:".mysql_error()); $database = mysql_select_db($db_database,$connect) or die("MySQl Said:".mysql_error()); $login = mysql_real_escape_string($_POST['user']); $pwd = mysql_real_escape_string($_POST['pwd']); $link = mysql_query("SELECT * FROM `pilots` where login='$login' and pwd='$pwd'") or die("MySQL Said:".mysql_error()); $count = mysql_num_rows($link); $data = mysql_fetch_assoc($link); $lname = $data["lname"]; $hub = $data["hub"]; $pwd = $data["pwd"]; $fname = $data["fname"]; $login= $data["login"]; $status= $data["status"]; $newp = mysql_query("SELECT * FROM `pilots` where status ='0'") or die("MySQL Said:".mysql_error()); $newprow = mysql_num_rows($newp); $result = count($newp); if($count == 1) { if($data['status'] == 0) { echo '<center>Your Account Is Not Active.</center>'; } else { if($data['status'] == 2) { echo '<center><FONT COLOR =ff001b>Your Account Has Been Suspended.</center></FONT COLOR>';?> <center><a href="logout.php">Log Out</a></br></center> <? } else { if($data['status'] == 3) { echo '<center>You Are Currently On L.O.A</center>';?> <a href="rfileloa.php?login=<? echo "{$data["login"]}"?>">Return From L.O.A</a></br><? } else { $_SESSION['SESS_LOGGEDIN'] = TRUE; $_SESSION['SESS_LNAME'] = $lname; $_SESSION['SESS_HUB'] = $hub; $_SESSION['SESS_FNAME'] = $fname; $_SESSION['login'] = $login; $_SESSION['status'] = $status; ?> <body link="#0066FF" vlink="#0066FF" alink="#0066FF"> <center>Welcome Back <? echo"$fname"; ?> <? echo"$lname"; ?></center> <center> <h7><i><b>Pilots Panel</b></i></h7></br> <a href="?page=pirepform&lname=<? echo "{$data["lname"]}"?>">File Pirep</a></br> <a href="?page=fileloa&login=<? echo "{$data["login"]}"?>">File LOA</a></br> <a href="#">Signatures</a></br> <A HREF="?page=profile&login=<? echo "{$data["login"]}"?> ">My Profile</a></br> <a href="?page=editp&login=<? echo "{$data["login"]}"?>">Edit My Profile</a></br> <a href="?page=events">Events</a></br> <a href="?page=rosterphp">VIew Roster</a></br> <a href="#"><font color="#FF0000">Resignation Form</font Color></br> <a href="logout.php">Log Out</a></br> <br> <h7><i><b>Pilots Tools</b></i></h7></br> <a href="http://www.fspassengers.com/"> FS Passengers</a></br> </center> <?php if($data['hm'] == 1) {?> <center> <h7><i><b>Hub Manager Panel</b></i></h7></br> <a href="edithub.php?hub=<?php echo $data['hub']; ?>">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> </center> <?php } if($data['fm'] == 1) {?> <center> <h7><i><b>Fleet Manager Panel</b></i></h7></br> <a href="addaircraft.php">Add Aircraft</a></br> <a href="manageaircraft.php">Manage Aircraft</a> </center> <?php } if($data['ed'] == 1) {?> <center> <h7><i><b>Events Director Panel</b></i></h7></br> <a href="?page=addevent">Add Event</a></br> <a href="?page=manageevents">Manage Events</a></br> <a href="postnews.php">Post News</a></br> </center> <?php } if($data['hr'] == 1) { ?> <center> <h7><i><b>Human Rescources Panel</b></i></h7></br> <a href="?page=newpilots">New Pilots</a></br> <a href="?page=editpilots">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <a href="?page=addnews">Post News</a></br> <a href="?page=editnews">Edit News</a></br> <?php } if($data['bm'] == 1) {?> <center> <h7><i><b>Executive Staff Panel</b></i></h7></br> <a href="edithub.php?hub=<?php echo $data['hub']; ?>">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> <a href="addevent">Add Event</a></br> <a href="manageevents.php">Manage Events</a></br> <a href="?page=addnews">Post News</a></br> <a href="?page=editnews">Edit News</a></br> <a href="pilotrec.php">Pilot Records</a></br> <a href="?page=newpilots&staffid=<? echo "{$data["login"]}"?>">New Pilots</a> <font color="#0066FF" size="3" face="Times New Roman, Times, serif"><b><? echo"$newprow"; ?></font></b></br> <a href="?page=editpilots">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <?php } } } } } else {?> <script>javascript:alert("Log In Failed!")</script> <? echo '<center><FONT COLOR =ff001b> Your <i>Pilot ID And/Or Password</i> is wrong!</center></FONT COLOR>';?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><p align="center"> <input type="submit" name="login" value="Login"> </p> <p align="center"> <a href="#">Forgot Password</a></p></td> </tr> </table> <? }?> <? } else {?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><p> <input type="submit" name="login" value="Login"> </p> <p><a href="#">Forgot Password</a> </p></td> </tr> </table> <?php } ?> <font color="#0066FF" size="3"> However if the users goes to another page this chunk of the site goes back to the login form instead of displaying all the user options. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-757309 Share on other sites More sharing options...
topflight Posted February 8, 2009 Author Share Posted February 8, 2009 any other suggestions? Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-757458 Share on other sites More sharing options...
premiso Posted February 8, 2009 Share Posted February 8, 2009 You never check if the session variable isset. If that variable isset then the user is logged on, so show them their options. You check for $_POST, but if the user is just browsing pages, $_POST is not going to help you, you need see if $_SESSION['login'] has been set etc. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-757466 Share on other sites More sharing options...
topflight Posted February 11, 2009 Author Share Posted February 11, 2009 Is their anymore suggestions I really need help and this is like the only thing delaying me on putting my site up. Once again here is my current login code <? session_start(); ?> <? if(isset($_POST['user'])) { //Include Config File For DB info.. include 'db.php'; //Connect TO The MySQL Server $connect = mysql_connect($db_host,$db_username,$db_password) or die("MySQL Said:".mysql_error()); $database = mysql_select_db($db_database,$connect) or die("MySQl Said:".mysql_error()); $login = mysql_real_escape_string($_POST['user']); $pwd = mysql_real_escape_string($_POST['pwd']); $link = mysql_query("SELECT * FROM `pilots` where login='$login' and pwd='$pwd'") or die("MySQL Said:".mysql_error()); $count = mysql_num_rows($link); $data = mysql_fetch_assoc($link); $lname = $data["lname"]; $hub = $data["hub"]; $pwd = $data["pwd"]; $fname = $data["fname"]; $login= $data["login"]; $status= $data["status"]; $newp = mysql_query("SELECT * FROM `pilots` where status ='0'") or die("MySQL Said:".mysql_error()); $newprow = mysql_num_rows($newp); $result = count($newp); if($count == 1) { if($data['status'] == 0) { echo '<center>Your Account Is Not Active.</center>'; } else { if($data['status'] == 2) { echo '<center><FONT COLOR =ff001b>Your Account Has Been Suspended.</center></FONT COLOR>';?> <center><a href="logout.php">Log Out</a></br></center> <? } else { if($data['status'] == 3) { echo '<center>You Are Currently On L.O.A</center>';?> <a href="rfileloa.php?login=<? echo "{$data["login"]}"?>">Return From L.O.A</a></br><? } else { $_SESSION['SESS_LOGGEDIN'] = TRUE; $_SESSION['SESS_LNAME'] = $lname; $_SESSION['SESS_HUB'] = $hub; $_SESSION['SESS_FNAME'] = $fname; $_SESSION['login'] = $login; $_SESSION['status'] = $status; ?> <body link="#0066FF" vlink="#0066FF" alink="#0066FF"> <center>Welcome Back <? echo"$fname"; ?> <? echo"$lname"; ?></center> <center> <h7><i><b>Pilots Panel</b></i></h7></br> <a href="?page=pirepform&lname=<? echo "{$data["lname"]}"?>">File Pirep</a></br> <a href="?page=fileloa&login=<? echo "{$data["login"]}"?>">File LOA</a></br> <a href="#">Signatures</a></br> <A HREF="?page=profile&login=<? echo "{$data["login"]}"?> ">My Profile</a></br> <a href="?page=editp&login=<? echo "{$data["login"]}"?>">Edit My Profile</a></br> <a href="?page=events">Events</a></br> <a href="?page=rosterphp">VIew Roster</a></br> <a href="#"><font color="#FF0000">Resignation Form</font Color></br> <a href="logout.php">Log Out</a></br> <br> <h7><i><b>Pilots Tools</b></i></h7></br> <a href="http://www.fspassengers.com/"> FS Passengers</a></br> </center> <?php if($data['hm'] == 1) {?> <center> <h7><i><b>Hub Manager Panel</b></i></h7></br> <a href="?page=addnews_hub">Add News</a></br> <a href="?page=edithub">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> </center> <?php } if($data['fm'] == 1) {?> <center> <h7><i><b>Fleet Manager Panel</b></i></h7></br> <a href="addaircraft.php">Add Aircraft</a></br> <a href="manageaircraft.php">Manage Aircraft</a> </center> <?php } if($data['ed'] == 1) {?> <center> <h7><i><b>Events Director Panel</b></i></h7></br> <a href="?page=addevent">Add Event</a></br> <a href="?page=manageevents">Manage Events</a></br> <a href="postnews.php">Post News</a></br> </center> <?php } if($data['hr'] == 1) { ?> <center> <h7><i><b>Human Rescources Panel</b></i></h7></br> <a href="?page=newpilots">New Pilots</a></br> <a href="?page=editpilots">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <a href="?page=addnews">Post News</a></br> <a href="?page=editnews">Edit News</a></br> <?php } if($data['bm'] == 1) {?> <center> <h7><i><b>Executive Staff Panel</b></i></h7></br> <a href="?page=edithub">Edit Hub Page</a></br> <a href="apppireps.php?hub=<?php echo $data['hub']; ?>">Approve Pireps</a></br> <a href="promote.php?hub=<?php echo $data['hub']; ?>">Promote Pilot</a></br> <a href="awards.php">Grant Award</a></br> <a href="addevent">Add Event</a></br> <a href="manageevents.php">Manage Events</a></br> <a href="?page=addnews">Post News</a></br> <a href="?page=editnews">Edit News</a></br> <a href="pilotrec.php">Pilot Records</a></br> <a href="?page=newpilots&staffid=<? echo "{$data["login"]}"?>">New Pilots</a> <font color="#0066FF" size="3" face="Times New Roman, Times, serif"><b><? echo"$newprow"; ?></font></b></br> <a href="?page=editpilots">Edit Pilots</a></br> <a href="viewcomments.php">View Comments</a></br> <a href="viewsitecomments.php">View Site Comments</a></br> <?php } } } } } else {?> <script>javascript:alert("Log In Failed!")</script> <? echo '<center><FONT COLOR =ff001b> Your <i>Pilot ID And/Or Password</i> is wrong!</center></FONT COLOR>';?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><p align="center"> <input type="submit" name="login" value="Login"> </p> <p align="center"> <a href="#">Forgot Password</a></p></td> </tr> </table> <? }?> <? } else {?> <style type="text/css"> .idBox { width:50px; } .passwordBox { width:80px; } </style> <table border="0" align="center"> <form action="<? $_SERVER['PHP_SELF']; ?>" method="post"> <tr> <td align="center">ID:</td><td align="center">ASA<input type="text" name="user" class="idBox"></td> </tr> <tr> <td align="center">Password:</td><td align="center"><input type="password" name="pwd" class="passwordBox"></td> </tr> <tr> <td></td><td align="center"><p> <input type="submit" name="login" value="Login"> </p> <p><a href="#">Forgot Password</a> </p></td> </tr> </table> <?php } ?> <font color="#0066FF" size="3"> Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-760064 Share on other sites More sharing options...
topflight Posted February 12, 2009 Author Share Posted February 12, 2009 Please please is their anybody who knows how to fix this problem? Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-760089 Share on other sites More sharing options...
topflight Posted February 12, 2009 Author Share Posted February 12, 2009 I am really lost and don't know what to do is their anybody who can help/give advise to. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-760141 Share on other sites More sharing options...
PFMaBiSmAd Posted February 12, 2009 Share Posted February 12, 2009 Starting a new thread for this exact same code and problem, probably lost you some of the help you were getting. Quote Link to comment https://forums.phpfreaks.com/topic/144187-my-login-script/#findComment-760320 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.