Syntax problem with php Update Statement (1 Viewer)

cyd44

Registered User.
Local time
Today, 07:34
Joined
Oct 30, 2011
Messages
85
I am trying to update a password field in a MySql Databse from a php web page. My code is as follows:-
Code:
$qry = "UPDATE patient SET password= '".md5($_POST['password'])."'" WHERE UID = ".$MyName."";
 $result = @mysql_query($qry);

I am getting a parse error message which points to the $qry line above. The logic is a simple form to change password for a user. $ MyName is captured from the session ID.

Can someone please help
 

Users who are viewing this thread

Top Bottom