Hi im working on my web site i can get the script to connect to the mysql but can’t get the page to update the member info when they submit to update i get a blank screen please help
my admin works like a dream with updating the info i just cant get the member part rite.
here is my script if any one knows where im going wrong.
Members Login Area | |
Member's ID | |
Password | |
Forgot Your Password? | |
"; $id=$_SESSION["id_session"]; $rs = mysql_query("select * from members where ID=$id"); $arr=mysql_fetch_array($rs); $check=0; $check=1; $db_field[1]=$_POST["fname"]; $db_field[2]=$_POST["username"]; $db_field[3]=$_POST["sponsor"]; $db_field[4]=$_POST["city"]; $db_field[5]=$_POST["state"]; $db_field[6]=$_POST["country"]; $db_field[7]=$_POST["zip"]; $db_field[8]=$_POST["email"]; $query="update members set Name='$db_field[1]', Username='$db_field[2]', Sponsor='$db_field[3]', City='$db_field[4]', State='$db_field[5]', Country='$db_field[6]', Zip='$db_field[7]', Email='$db_field[8]' where ID=$db_field[0]"; $rs = mysql_query($query); } else { print "Invalid Password ! Account cannot be updated!
"; } middle(); } } ?>
|
|||||||||||||||||||||
Update your Personal Information | |
FULL NAME* | |
GDI Username* | |
GDI Sponson* | |
CITY* | |
STATE* | |
COUNTRY* | |
Postal Code/ZIP CODE* | |
EMAIL ADDRESS* | |
PASSWORD* | |
PASSWORD* | |
?>