Get error message, need help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi David

>    // Query Database with username and encrypted password
>  #$myquery = "SELECT * FROM user WHERE username = '" . $user
>  #$myquery = .'" AND password = '" . crypt($password, "xpz8ty") . "'";
>  #$result = mysql_query($myquery);

In the first line of the query there is no semicolon at the end of the
line.
To define strings over several lines you have to write *.=* instead of *=.*
Try this:

    // Query Database with username and encrypted password
$myquery = "SELECT * FROM user WHERE username = '" . $user."'";
$myquery .= " AND password = '" . crypt($password, "xpz8ty") . "'";
$result = mysql_query($myquery);

Regards
Conni


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux