> -----Original Message-----
> From: Augusto Cesar Castoldi [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, September 12, 2001 9:46 AM
> To: Schill, Johannes
> Cc: [EMAIL PROTECTED]
> Subject: Re: [PHP] Is it a mysql AND/OR php BUG???
>
>
> the function isn't decoding right.
>
> > > function decode($decode_str, $pass_str)
> > > {
> > > $encode_str = addslashes($encode_str);
> > > $sql="select decode(\"$decode_str\",
> > > \"$pass_str\")";
> > > echo htmlspecialchars($sql)."<br>";
> > > $data = mysql_query($sql) or die ("Erro crypt
> > 2.");
> > > $row = mysql_fetch_row($data);
> > > return $row[0];
> > > }
Should you maybe be using $decode_str instead of $encode_str in the
first line of this function?
---
Mark Roedel | "Blessed is he who has learned to laugh
Systems Programmer | at himself, for he shall never cease
LeTourneau University | to be entertained."
Longview, Texas, USA | -- John Powell
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]