05.02.2015, 14:23
Well, I am scripting a RP gamemode from scratch and I decided it would be the best idea to script it via MySQL. I started to script it however I failed to connect my database apparently.
Here is MySQL Log:
Here is my MySQL Connection Script:
Of course this is on OnGameModeInIt so it triggers mysql_connect. Here is my MySQL details:
I am more or less sure about I don't have a password set for my XAMPP, any ideas? I am really clueless.
Here is MySQL Log:
Код:
[Thu Feb 05 16:43:54 2015] Function: mysql_init executed with result: "0". [Thu Feb 05 16:43:54 2015] Function: mysql_init executed with result: "1". [Thu Feb 05 16:43:54 2015] Error (1): Failed to connect. Access denied for user 'root'@'localhost' (using password: YES).
pawn Код:
new Connect = mysql_connect(mysql_host, mysql_user, mysql_password, mysql_database, mysql, 1);
if(Connect)
{
print("[MySQL]: MySQL connection successfully initialized");
}
pawn Код:
#define mysql_host "localhost"
#define mysql_user "root"
#define mysql_password ""
#define mysql_database "server"