Problem using BFStats to generate server stats

Post Reply
Diamondback
Posts: 589
Joined: Mon Oct 01, 2012 3:13 pm
Location: Canada
Contact:

Problem using BFStats to generate server stats

Post by Diamondback »

I am having issues using BFStats, which is a program which was made by Mario Kohler years ago to convert CSV spreadsheets generated by BFSM (statistics.csv) to HTML pages that can be uploaded via FTP to a website.

I used the following tutorial to try and generate the HTML pages: http://elitesniperserver.com/media/tuto ... e.asp?id=9

First, I downloaded and installed the latest Java SDK + Runtime Kit as pointed out by the tutorial by visting this website: http://www.oracle.com/technetwork/java/ ... 33151.html

I then downloaded the "Java SE Development Kit 8u172" for Windows x64 (jdk-8u171-windows-x64.exe). After that I downloaded and installed the BFStats.zip and extracted it to a folder on my Desktop called "Stats". Here is the file directory inside this Stats folder:

Image

The statistics.csv file was generated by the BFRM v2.01 using the following settings (see the image below). I don't know if enabling Event log compression is the issue here, but I doubt it.

Image

Now the tricky part. After having edited the "run.cmd" file found inside the "bin" folder with a text editor to point to the path where I have stored the statistics.csv file, I run the file and it gives me the following errors:

Image

Basically it's saying that the statistics.csv file is empty even though it is not (red rectangle). I have opened it many times and can see all the games being logged there, with the player names, their scores, pings, deaths, IPs, etc. Running the file with Administrator Rights also does nothing and does not generate the HTML files inside the "www" folder.

I am using Windows 10 Home 64-bit. Has anyone else had problems with this program to generate HTML files from the CSV file?
See my Strasbourg map project here.
freddy
Posts: 1267
Joined: Sun Oct 18, 2009 4:58 pm

Re: Problem using BFStats to generate server stats

Post by freddy »

Not sure it can handle compressed logs, also i think the webpages uses php, and that broke after some php update.
Diamondback
Posts: 589
Joined: Mon Oct 01, 2012 3:13 pm
Location: Canada
Contact:

Re: Problem using BFStats to generate server stats

Post by Diamondback »

freddy wrote:Not sure it can handle compressed logs, also i think the webpages uses php, and that broke after some php update.
What program do you use to generate server stats?
See my Strasbourg map project here.
freddy
Posts: 1267
Joined: Sun Oct 18, 2009 4:58 pm

Re: Problem using BFStats to generate server stats

Post by freddy »

I used the same program as you have, but it was before the php update. On windows systems you can try an older XAMPP package (maybe around 2012?) https://sourceforge.net/projects/xampp/ ... 20Windows/

It might be a bit risky with older software conserning security holes and such, so its safer to run it on a virtual machine or something the like. https://www.virtualbox.org/

edit: just checked my webhost, and there is some different php options, but the same time some warning about it?
Attachments
1_php.jpg
Grabbi
Posts: 42
Joined: Wed Aug 03, 2011 3:37 pm
Location: Germany
Contact:

Re: Problem using BFStats to generate server stats

Post by Grabbi »

I remember I had to fix some code 2010 inside BFStats.class to get it working and extend the HTML output with a PHP cover templating to adjust it.

As soon as a player name contained a comma (,) in the input string the whole parsing process was broken and entries have been ignored.

PHP Cover templating:

Code: Select all

<?
//include("../../../templates/original/head.html");
$head = file_get_contents("../../head_monthly.html");

$html = file_get_contents("../index[ENTER 1-6 here].html");
$html = str_replace("playername=\"","playername=",$html); 
$html = str_replace("\" &search=players\">\"","&search=players\">",$html); 
$html = str_replace("\"</a>&nbsp;","</a>&nbsp;",$html); 
echo $head;
echo $html;
?>
Result should look like this then:
http://www.forgottenhope1.com/serversta ... index2.php (turn down the volume of your PC)

Greetings


Grabbi
Attachments
BFStats.rar
Fixed BFStats.class
(2.97 KiB) Downloaded 1587 times
[url=bf1942://85.214.226.169:14567]Image[/url]
Grabbi
Posts: 42
Joined: Wed Aug 03, 2011 3:37 pm
Location: Germany
Contact:

Re: Problem using BFStats to generate server stats

Post by Grabbi »

same topic with solution:

http://bfmods.com/viewtopic.php?f=54&t=47938


Greetings



Grabbi
[url=bf1942://85.214.226.169:14567]Image[/url]
davidson02
Posts: 5
Joined: Tue Apr 05, 2022 3:30 am

Re: Problem using BFStats to generate server stats

Post by davidson02 »

Grabbi wrote: Thu Feb 06, 2020 8:36 pm same topic with solution:

http://bfmods.com/viewtopic.php?f=54&t=47938


Greetings



Grabbi

I appreciate that.
https://www.drywallaugusta
ampva301
Posts: 9
Joined: Wed Jun 22, 2022 6:52 am

Re: Problem using BFStats to generate server stats

Post by ampva301 »

I haven't encountered similar issues so I'm following this up. But if you're having a problem with how to repair plaster, I'm here to help.
Post Reply