PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
if ($addemail!=$email) $check=check_email($addemail,$username);
if (empty($check)){
include("datafile/useremail.txt"); //----here
$o=count($userid);$i=0;
while ($i < $o){
if($wandererboardid==$useridї$i]) $newdataї]="\$emailї]='$addemail';\$useridї]='$useridї$i]';"."\n";
else $newdataї]="\$emailї]='$emailї$i]';\$useridї]='$useridї$i]';"."\n";
$i++;
}
$newdata=implode("",$newdata);
writetofile('datafile/useremail.txt',"<?php\n".$newdata,"w");
}
function check_email($addemail,$username){
include("datafile/useremail.txt"); //--- here
$check_email = array_keys($email,$addemail);
if ($check_email){$id=$check_emailї0];
$err_msg="Your E_mail address:$addemail has been<a href=wdbprofile.php?job=show&target=$useridї$id]>$useridї$id]</a> used!Please go back and rewrite another one。<br>";
}
return $err_msg;
}
function check_email($addemail,$username){
include_once("datafile/useremail.txt");
$check_email = array_keys($email,$addemail);
if ($check_email){$id=$check_emailї0];
$err_msg="Your E_mail address:$addemail has been<a href=wdbprofile.php?job=show&target=$useridї$id]>$useridї$id]</a> used!Please go back and rewrite another one。<br>";
}
return $err_msg;
}
if ($addemail!=$email) $check=check_email($addemail,$username);
if (empty($check)){
include_once("datafile/useremail.txt");
$o=count($userid);$i=0;
while ($i < $o){
if($wandererboardid==$useridї$i]) $newdataї]="\$emailї]='$addemail';\$useridї]='$useridї$i]';"."\n";
else $newdataї]="\$emailї]='$emailї$i]';\$useridї]='$useridї$i]';"."\n";
$i++;
}
$newdata=implode("",$newdata);
writetofile('datafile/useremail.txt',"<?php\n".$newdata,"w");
}