Jump to content

please help authentication error


runnerjp

Recommended Posts

hey guys i am makeing a profile site.. basicly i keep getting this error when trying to authenticate a member login!


Fatal error: Call to undefined function: authenticate() in /home/runnerse/public_html/test.php on line 24

here are codes

my main page is

[code]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="undefined">
<head>
<title>HomePage</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
</head>
<body bgcolor="#ffffff" background="image/background.jpg" link="#0080ff" vlink="#0080ff" alink="#000000" leftmargin="0" topmargin="0" >
</HEAD>
<BODY>
<div style="position: absolute; top: 156px; left: 200px; height: 19px; width: 92px;"> <font color="#FFFFFF">Shout-Box</font></div>
<div style="position: absolute; top: 173px; left: 200px"> <a href= "javascript:TagBox=void(window.open('http://www.runnerselite.com/tag/tag.php','TagBox','scrollbars=1,width=400,height=600,top=60,left=400'))">Post a shout</a> </div>
<div style="position: absolute; top: 165px; left: 290px">
  <?php include("tag/maq.php")?>
</div>
<div style="position: absolute; top: 49px; left: 250px"> <img src="http://www.runnerselite.com/image/LOGO.jpg" /> </div>
<div style="position: absolute; top: 5px; left: 35px"> <font color="#CCCCCC" size="-1">-Quick links-</font> </div>
<div style="position: absolute; top: 5px; left: 145px"> <font color="#CCCCCC" size="-1"><a href="somepage.html" style="color: #cccccc">Email@</a></a></font> </div>
<div style="position: absolute; top: 5px; left: 255px"> <font color="#CCCCCC" size="-1"><a href="somepage.html" style="color: #cccccc">Forum</a></a></font> </div>
<div style="position: absolute; top: 5px; left: 365px"> <font size="-1"><a href="somepage.html" style="color: #cccccc">Profiles</a></a></font> </div>
<div style="position: absolute; top: 5px; left: 475px"> <font color="#CCCCCC" size="-1"><a href="somepage.html" style="color: #cccccc">Homepage</a></a></font> </div>
<div style="position: absolute; top: 216px; left: 185px">
  <?php include("http://www.runnerselite.com/members/require/config.php");
require("http://www.runnerselite.com/require/authmember.php");
$auth=authenticate($login, $password);
include("http://www.runnerselite.com/members/get_config.inc.php");
$content="http://www.runnerselite.com/members/index.inc.php";
if ($auth[error]) {$menu="http://www.runnerselite.com/members/menu_u.inc.php";} else {$menu="http://www.runnerselite.com/members/menu_v.inc.php";}
?>
  <?php   include("http://www.runnerselite.com/members/include/adminerr.inc.php");
            if($auth[error]) { include("http://www.runnerselite.com/members/include/messages/index_unverified.inc.php"); }
            else { include("http://www.runnerselite.com/members/include/messages/index_verified.inc.php"); }?>
</div>
</body>
</html>
[/code]

and here is my authenticate code

[code]<?
function authenticate ($login, $password) {
global $db_name, $tbl_members, $incpath;
include("http://www.runnerselite.com/members/error.inc.php");
$valid = mysql_fetch_array(mysql_db_query($db_name, "SELECT * FROM $tbl_members WHERE login='$login'"));
if ($login) {
if ($password ==  crypt($valid[password], $login)) {
if ($valid[enabled] ==  "yes") {
$result=$valid;
} else {
$result[error]=$strError700;}
} else {
$result[error]=$strError800;}
} else {
$result[error]=$strError200;}
return $result;
}
?>[/code]

what am i doing wrong?? and how can i solve it??
Link to comment
https://forums.phpfreaks.com/topic/30218-please-help-authentication-error/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.