Jump to content

Parse error


c172cpt

Recommended Posts

I have been working debugging a site for quite some time and i have a parse error in this function that i cant solve.

in a nutshell the function recieves post data then verifys that data was sent from user and then the part with the error is an if/then statement that is supposed to

determine if no new username was entered => change the mysql command approapiatly

else

check that the current username is not the same and the new => error out

otherwise change the mysql command to include the new username

then display status output

here is the code can any one please help find the error

 

//********************************

if (!isset($newuname){

  $updatelogin = "update users set password=md5('$password'), question='$question', answer='$answer' where username='$uname'"

}else{

if ($currentuname == $newuname){

error("Your New Username Cannot Be The Same As The Old Username");

//update with the username

}else{

$updatelogin = "update ignore users set username='$newuname', password=md5('$password'), question='$question', answer='$answer' where username='$uname'"

}}

$status = getemsql($updatelogin, 'accounts');

 

if (!$status}{

error("An Error Has Occured Please Try Again.");

}else{

status("Login Information Updated, Please Logout and Login to Finish Update");

}

//*************************

 

btw the error function is a js popup that goes back to form and the status function is the same popup that does not go back

 

 

thanks in advance

-scott-

Link to comment
https://forums.phpfreaks.com/topic/63450-parse-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.