i want to update actuall pass in database.. user password.. this is my core.php
PHP Code:
////////////////////////////////////////////////////Register
function register($name,$pass,$usex,$bday,$uloc,$lang,$email, $ubr)
{
$execms = mysql_query("SELECT * FROM ibwf_users WHERE name='".$name."';");
if (mysql_num_rows($execms)>0){
return 1;
}else{
$pass = md5($pass);
$validation = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='vldtn'"));
if($validation[0]==1)
{
$validated=0;
}else{
$validated=1;
}
$reg = mysql_query("INSERT INTO ibwf_users SET name='".$name."', pass='".$pass."', birthday='".$bday."', sex='".$usex."', location='".$uloc."', regdate='".time()."',validated='".$validated."', lang='".$lang."', email='".$email."', ipadd='".getip()."', browserm='".$ubr."'");
if ($reg)
{
$uid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_users WHERE name='".$name."'"));
$msg = "hello /reader greetings from all FriendsCare staff, We are glad to have you here, welcome. to our big happy family! plz read /faq and Explore other featurs. ENJOY FriendsCare! We do our best for you as well as want you to participate in our forum to make us proud. Hope you will enjoy your stay here!! Important Note- Only upload your own pictures in UserGallery!! thanks!! music. ";
$msg = mysql_escape_string($msg);
autopm($msg, $uid[0]);
return 0;
}else{
return 2;
}
}
}
function validation()
{
$getval = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='vldtn'"));
if($getval[0]=='1')
{
return true;
}else
{
return false;
}
}
/////////////////////// GET ibwf_users user id from nickname
function getuid_nick($nick)
{
$uid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_users WHERE name='".$nick."'"));
return $uid[0];
}
function isheadadmin($uid)
{
$admn = mysql_fetch_array(mysql_query("SELECT perm FROM ibwf_users WHERE id='".$uid."'"));
if($admn[0]>=3)
{
return true;
}else{
return false;
}
}
function isheadadmin2($uid)
{
$admn = mysql_fetch_array(mysql_query("SELECT perm FROM ibwf_users WHERE id='".$uid."'"));
if($admn[0]==3)
{
return true;
}else{
return false;
}
}
Comment