FW: Cannot Redeclare?
| From: | Stephen Craton | Date: | Mon, 23 Sep 2002 02:55:53 +0000 |
| Subject: | FW: Cannot Redeclare? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-117227@lists.php.net to get a copy of this message | ||
Hello,
I was just wondering...again...why the heck I keep getting this error.
I'm trying to make a function called login() and sometimes it works,
other times it hates me and gives me this error:
Fatal error: Cannot redeclare login() in
c:\apache\htdocs\wiredphp\member\funcs.php on line 5
Here's the contents of the function login():
function login($username, $password)
{
$sql = "select * from members where username='$username' and passwd =
password('$password')";
$result = mysql_query($sql, $wired);
if (!$result)
return 0;
if (mysql_num_rows($result)>0)
return 1;
else
return 0;
}
Please help. I don't see why this keeps happening...
Thanks,
Stephen
http://www.melchior.us
http://php.melchior.us
P.S. I'm sending this again because I don't know if the other got
through or not...