Posts: 13
Threads: 2
Joined: Aug 2011
Reputation:
0
Hi,
I got this thing: on bottom:
Warning: mysql_close(): 5 is not a valid MySQL-Link resource in C:\xampp\htdocs\UCP\index.php on line 56
line 56is: <? mysql_close($con); ?>
any help?
con - is $con = mysql_connect(SQL_SERVER, SQL_USERNAME, SQL_PASSWORD);
Posts: 288
Threads: 2
Joined: Sep 2009
connections had successful? I think no,because '5 is not a valid MySQL-Link resource ' -> mysql connection #5 ($con) isn't a valid connection ...
try with this:
if(mysql_ping($conn) <=0) die "fail to connect";
Posts: 13
Threads: 2
Joined: Aug 2011
Reputation:
0
Nop, don't work... Or this warning, or a lot of them
Posts: 13
Threads: 2
Joined: Aug 2011
Reputation:
0
Notice: Undefined variable: SQL_SERVER in C:\xampp\htdocs\nfengine\database.php on line 11
Notice: Undefined variable: SQL_USERNAME in C:\xampp\htdocs\nfengine\database.php on line 11
Notice: Undefined variable: SQL_PASSWORD in C:\xampp\htdocs\nfengine\database.php on line 11
Posts: 288
Threads: 2
Joined: Sep 2009
Quote:
Originally Posted by Lefon
Notice: Undefined variable: SQL_SERVER in C:\xampp\htdocs\nfengine\database.php on line 11
Notice: Undefined variable: SQL_USERNAME in C:\xampp\htdocs\nfengine\database.php on line 11
Notice: Undefined variable: SQL_PASSWORD in C:\xampp\htdocs\nfengine\database.php on line 11
|
Start with start.
http://www.w3schools.com/html/default.asp
http://www.w3schools.com/php/default.asp
http://dev.mysql.com/doc/refman/5.0/en/tutorial.html
$SQL_SERVER = "localhost";
$SQL_USERNAME = "root";
$SQL_PASSWORD ="pass"; // if mysql db don't have a pass,dont put $SQL_PASSWORD