Username:    Password:        Click Here To Signup     Forgotten Password
Main Menu
Online
Members: 0

Guests: 17

36.57.x.x download
38.99.x.x news
46.229.x.x forum
46.229.x.x forum
46.229.x.x dilbertplus
46.229.x.x forum
46.229.x.x forum
46.229.x.x forum
46.229.x.x dilbertplus
46.229.x.x forum
46.229.x.x forum
46.229.x.x forum
46.229.x.x forum
46.4.x.x forum
5.255.x.x forum
54.234.x.x forum
78.46.x.x forum

Last Seen

mrstipfan Wed 19:48
Gagi2 Mon 16:30
EFiNST0RM Sun 15:39
85filip58 Sun 12:14
brlight Tue 04:18

Newest Members

Forums
WAMP LOCALHOST: 'no database selected' when enter game ip address
konjako
Sat Aug 08 2015, 11:39AM
Posts: 3
Joined: Sat Aug 08 2015, 11:28AM
Registered Member #8352
Hai guys, I have started developing gaming websites. And what can I say, I'm doing well. Buuut... One client asked me to put in a website a game monitor, so I thought why not, it should not be very hard because I have already seen such php plugin like LGSL.

So, I was trying to install it but, unfortunately, unsuccessfully. To test, I use WAMP LOCALHOST STAND ALONE 5.8. I created database and everything else seems to be done well. But when I enter game server IP address and Port, it says "No database selected".

I checked lgsl_config, everything really seems to be fine. I mean, information about my database.

$lgsl_config['db']['server'] = "localhost";
$lgsl_config['db']['user'] = "root";
$lgsl_config['db']['pass'] = "";
$lgsl_config['db']['db'] = "servers";
$lgsl_config['db']['table'] = "lgsl";


This is my information. But it does not work

ADD:

Actually, this happens when I click any button, like "Save - keep cache". The same problem appears as well. Maybe I have forgotten something or installed it in a wrong way? Btw, in some lines of plugin, a had to change mysql to mysqli, because in my phpmyadmin it says it is deprecated.

Any help, guys, please??
85filip58
Sat Aug 08 2015, 11:48AM

Posts: 125
Joined: Wed Aug 01 2012, 08:39AM
Registered Member #7331
By the way you must change all your mysql_* function into mysqli_* functions, but I am not right in this case. In another case I can recomended to use my website where you can add your servers and you can use banners with graphs

Head Admin of ServerList: www.GameW.eu
Website
konjako
Sat Aug 08 2015, 02:25PM
Posts: 3
Joined: Sat Aug 08 2015, 11:28AM
Registered Member #8352
I think the problem lies in calling functions or sth like that. Do not excatly yet. Look at the code below:

lgsl_database();
$mysql_query  = "SELECT `id` FROM `{$lgsl_config['db']['prefix']}{$lgsl_config['db']['table']}` WHERE ".implode(" AND ", $mysql_where)." ORDER BY {$mysql_order}";
$mysql_result = mysqli_query($lgsl_database, $mysql_query) or die(mysql_error());
$server_list  = array();

When I use the script in this way (as default), error appears that theres is no connection with database. But function lgsl_database() is called! Which connects to database and selects table!

But when I use this instead

$lgsl_database  = mysqli_connect($lgsl_config['db']['server'], $lgsl_config['db']['user'], $lgsl_config['db']['pass']) or die(mysql_error());
$lgsl_select_db = mysqli_select_db($lgsl_database, $lgsl_config['db']['db']) or die(mysql_error());
$mysql_query  = "SELECT `id` FROM `{$lgsl_config['db']['prefix']}{$lgsl_config['db']['table']}` WHERE ".implode(" AND ", $mysql_where)." ORDER BY {$mysql_order}";
$mysql_result = mysqli_query($lgsl_database, $mysql_query) or die(mysql_error());
$server_list  = array();

error dissapears and appears in section where you have to type in IP and other stuff. Cannot it be that there is something wrong with this function? And because of that in other files plugin does not reach database??
85filip58
Sat Aug 08 2015, 04:20PM

Posts: 125
Joined: Wed Aug 01 2012, 08:39AM
Registered Member #7331
Maybe I try help you via skype, my skype is filip5824 but these days I have problem with my graphic card so.. when I will be available I help you. But you can send me request about skype contact.

Head Admin of ServerList: www.GameW.eu
Website
konjako
Sat Aug 08 2015, 04:34PM
Posts: 3
Joined: Sat Aug 08 2015, 11:28AM
Registered Member #8352
I would really appreciate it, filip! Thanks mate! I have already added you, my skype starts with "dus..." (I do not want to say my name in public ).
Wussie
Sun Aug 16 2015, 06:00PM

Posts: 437
Joined: Sun Mar 22 2009, 06:53AM
Registered Member #4938
Just try using the original php files in LGSL 5.8 with the old mysql_ statements, even if your phpmyadmin says it is deprecated. There's nothing wrong with the functions, they work fine for the rest of us.
And please tell me you set a proper password for your database...


Not working for you?
Don't forget to share the IP/ports of the offending server so that people can do tests and help you.
Oh, and if you're using a modified lgsl_protocol.php, make sure you disable the feed or it may NOT work!
Website
 

Jump:     Back to top


You are not logged in - Click Here To Signup

Username:    Password:   

Mini Buttons

.... © GreyCube.com - Richard Perry - Powered by e107.org