My code handler.php
...
// independent variables
$dbHost = "localhost";
$dbPort = 5432;
$dbName = "masi";
$dbUser = "masi";
$dbPassword = "123456";
$conn = "host=$dbHost port=$dbPort dbname=$dbName user=$dbUser password=$dbPassword";
$dbconn = pg_connect($conn);
$sql = "SELECT username, passhash_md5, email
FROM users$
WHERE username='a' // to get these data from lomake.php
AND email='a'
AND passhash_md5='a'";
$result = pg_query($conn, $sql);
if(!$result) {
echo "An error occurred - Masiii!\n";
exit;
}
?>
Ben "username = a", "e-posta = a" ve şifre koymak = "a" Firefox'ta komut handler.php işleyen bir forma. Ben olsun
Warning: pg_query(): supplied argument is not a valid PostgreSQL link resource in /var/www/sivusto/handler.php on line 56
An error occurred - Masiii!
Ben some examples at PHP.net olarak aynı sözdizimini kullanmak beri bug, nerede emin değilim.
How can you solve the bug?