selamlar,
bende mevcut bi quiz testi var bende bunu excel testine cevirmek istiyorum. ancak veritabanina baglanti hatalari aliyorum.
Warning: mysql_query() [function.mysql-query]: Access denied for user 'ODBC'@'localhost' (using password: NO) in c:\domains\art-niyet.org\wwwroot\odev\login.php on line 19
Warning: mysql_query() [function.mysql-query]: A link to the server could not be established in c:\domains\art-niyet.org\wwwroot\odev\login.php on line 19
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in c:\domains\art-niyet.org\wwwroot\odev\login.php on line 19
kodum ise su sekilde;
-login.php-
<?php
require_once("global.php");
if($_GET["logout"]) {
unset($_SESSION["Nickname"]);
header("Location: $_SERVER[HTTP_REFERER]");
exit;
}
if($_SESSION["Nickname"]) {
header("Location: index.php");
exit;
}
if($_GET["Nickname"]) {
$sql = "SELECT COUNT(*) FROM amm_users WHERE Nickname='$_GET[Nickname]' AND Active!=0";
list($uFound) = mysql_fetch_row(mysql_query($sql));
if($uFound) {
$_SESSION["Nickname"] = $_GET["Nickname"];
header("Location: index.php");
exit;
}
else {
$error = "<strong>$_GET[Nickname]</strong> isminde bir kullanıcı yok veya aktif değil.";
}
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtm...sitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta ***********="Content-Type" content="text/html; charset=iso-8859-9" />
<title>CaféTrivia</title>
<link href="style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div class="content">
<form id="" name="" method="get" action="">
<fieldset><legend>İsminiz veya lakabınız:</legend>
<input name="Nickname" type="text" class="text" id="Nickname" />
<input type="submit" value="Giriş" />
</fieldset>
</form>
<p><span class="marked"><?php echo $error; ?></span></p>
</div>
</body>
</html>
ayrıca;
-global.php-
<?php
session_start();
function sql_conn() {
$server = "localhost";
$username = "craftedwear";
$password = "";
$db = "craftedwear";
.... diye gidiyo
ben hata göremiyrum ama veritabanina bir turlu .. baglanamiyorum hata nerde olabilir.. tesekkurler


Alıntı ile Cevapla
Bu Konuyu Paylaşın !