password function

From: Date: Sun, 22 Sep 2002 12:23:14 +0000
Subject: password function
Groups: php.db 
Request: Send a blank email to php-db+get-21901@lists.php.net to get a copy of this message
hi, i want to encode a string that users enter with mysql password function. but sometimes this code works sometimes don't. mysql warns me: Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in ........ the code is: $result=mysql_query("select password(".$_POST['password'].")"); while ($p = mysql_fetch_array($result, MYSQL_ASSOC)): $pswrd=$p['password('.$_POST['password'].')']; endwhile; thanks...

« previous php.db (#21901) next »