volkv

CoD4X Serverlist Monitoring

Recommended Posts

Hey guys! Want to share with you a Servers Monitoring Widget I've just made which uses serverstatus.xml

Main Features

  • Simple and Fast - script just do parse your serverstatus.xml without using of anything else like MYSQL or RCON, so it much faster than original RCON+MYSQL(cache) monitorings
  • Enhanced playerslist with players divided by teams, including their Rank images and captions
  • Server Online Records - scripts will remember a number and time when it was maximum players online.
  • Server Online/Offline status information
  • Multi language - you can translate it by simple editing /lang/ files. Already translated into English and Russian.
  • Maps preview images (on hover) - previews for all deafault Call of Duty 4 maps
  • Widget ready - you can just include 'your_folder/index.php'; file from everywhere and it will be loaded.

Some Previews

serverlistplayerslist

Edited by volkv
  • Thanks 2

Share this post


Link to post
Share on other sites
29 minutes ago, bizon_75 said:

Thank you! I'll check it on my servers.

Waiting for bugreports ;)

P.S. on Invision Forums it can be done by using PHP widget with single line

<?php include 'your_monitoring_folder/index.php';

 

Edited by volkv

Share this post


Link to post
Share on other sites

Great post . Thank you .  ill be using this in my future projects . :rolleyes:

23 hours ago, volkv said:

Waiting for bugreports ;)

When there are no players in the server, it gives an error . ( Notice , Warning ) .


Notice: Undefined index: clients in C:\xampp\htdocs\ServerStats-XML\index.php on line 207

Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\ServerStats-XML\index.php on line 207
<?php foreach ($d['clients'] as $server_id => $server) { ?>
<?php } ?>

not a big deal . but wanted to mention it - if(isset()){} will do the trick . :) 

Share this post


Link to post
Share on other sites
7 hours ago, gwa99a9 said:

When there are no players in the server, it gives an error . ( Notice , Warning ) .

Yep, thanks for report. Needed check was missing... Whats your PHP ver. btw?

Share this post


Link to post
Share on other sites
1 hour ago, volkv said:

Yep, thanks for report. Needed check was missing... Whats your PHP ver. btw?

i tested it on both PHP 5.5.38 and PHP 7.0.25

Share this post


Link to post
Share on other sites

@volkv hey. 
I'm trying to read serverstatus.xml but how will I get the lines written in Cyrillic?

Share this post


Link to post
Share on other sites
Posted (edited)

I get this error

Notice: Undefined offset: 1 in /var/www/html/serverlist/index.php on line 179

Warning: file_put_contents(/var/www/html/serverlist/inc/max): failed to open stream: Permission denied in /var/www/html/serverlist/index.php on line 182

 

Edited by wkuzma

Share this post


Link to post
Share on other sites
Posted (edited)

chown -hR webserveruser:webservergroup /var/www/html/serverlist

Replace webserveruser and webservergroup with your correspondig webserver user and group. With nginx usually www-data

Edited by AlexC

Share this post


Link to post
Share on other sites
5 hours ago, AlexC said:

chown -hR webserveruser:webservergroup /var/www/html/serverlist

Seeting the file to r fixed it

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.