hiii all....i am building a website(of course its in php)..i had created a login page and a home page...the problem is many time login is successful and many time a error occur "UNDEFINED INDEX on $_post[] line " on the same page with the same coding...so is there anyway to overcome this problem??
the code is very simple :
/* in the login page*/
<form method="post" action="checklogin.php">
<p>Email-id:<input type="text" name ="emailid"></p>
<p><input type="password" name ="password"></p>
<input type="submit" name ="submit" value="login">
</form>
/*in checklogin.php file*/
1st i made a connection with database and with the combination of emailid and password i checked the database,
the error occur due in these two lines(already told you, not always only sometimes)...
$email=$_POST['emailid'];
$password=$_POST['password'];
php error resolve
Moderator: General Moderators
php error resolve
Last edited by bluestar on Thu Mar 17, 2011 8:30 am, edited 1 time in total.
-
internet-solution
- Forum Contributor
- Posts: 220
- Joined: Thu May 27, 2010 6:27 am
- Location: UK
Re: php error resolve
You will get a better answer, if you share your code!