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

Guests: 11

175.44.x.x forum
192.151.x.x news
209.123.x.x news
220.250.x.x forum
36.248.x.x forum
5.63.x.x news
5.9.x.x news
50.16.x.x forum
58.22.x.x forum
66.249.x.x fpw
72.44.x.x forum

Last Seen

nott Sat 03:09
Zipps Sat 02:47
mkden Sat 01:26
qwas Fri 14:44
xMin Fri 14:04

Newest Members

Forums
Server code wont work on website
Seppo
Fri Dec 31 2010, 01:55AM
Posts: 10
Joined: Fri Dec 31 2010, 01:52AM
Registered Member #6487
Hi im using the standalone version and trying to get the servers showing up on my website, i added

require "lgsl_files/lgsl_class.php";
$server_list = lgsl_query_group();
$total = lgsl_group_totals($server_list);
echo " Servers: {$total['servers']}
Servers Online: {$total['servers_online']}
Servers Offline: {$total['servers_offline']}
Players: {$total['players']}
Max Players: {$total['playersmax']} ";


I can see my website asuseall but were i placed the server it says the same as the code i putted :/
Rich
Sat Jan 01 2011, 06:10PM
Posts: 1700
Joined: Wed Nov 26 2003, 04:30PM

You mean you see the text ?

You need to put php tags around the code.

<?php

code

?>

Website
Seppo
Sun Jan 02 2011, 05:57AM
Posts: 10
Joined: Fri Dec 31 2010, 01:52AM
Registered Member #6487
If i do that i get mysql errors
Rich
Mon Jan 03 2011, 09:22AM
Posts: 1700
Joined: Wed Nov 26 2003, 04:30PM

What are the errors ?

If you are tring to load a CMS version of LGSL in a non CMS page, you will need to edit the lgsl_config.php and put in your database settings.

If you are using the stand-alone, and its your site making the SQL errors, you need to create the LGSL table in the site database, and change the lgsl_config.php to match.

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