Author Topic: Basic StdLog parser for statistics/ranking  (Read 13455 times)

Zorchenhimer

  • Autococker
  • Posts: 2614
Re: Basic StdLog parser for statistics/ranking
« Reply #20 on: February 27, 2008, 05:34:09 PM »
First you need PHP. Then you need to extract the file to anywhere. Now copy the logfile you want to parse into that directory. Open a command prompt, cd to the directory, and type:
Code: [Select]
./teststdlog.php ./logfile.here 0It should create a file called output.txt that looks like this: http://digitalpaint.therisenrealm.com/downloads/sdk/libdpstdlog/output.txt

Pitfalls:
Unless you host a server you won't have a logfile.
Until someone writes a nice script to make a webpage from it, the output is fairly difficult to read.

The only way I was able to get an output was using the following command line:
Code: [Select]
$ /usr/bin/php -f ~/stats/example.php ~/stats/server27910.log y

This is what I get when I try it the way you explain it:
Code: [Select]
$ ./example.php ./server27910.log 0
Extension './example.php' not present.

ViciouZ

  • Map Committee
  • Autococker
  • Posts: 2227
Re: Basic StdLog parser for statistics/ranking
« Reply #21 on: February 27, 2008, 05:48:01 PM »
Bleh, silly me. Nabbed the wrong bit of code from sk89q's post. Thanks for telling me why you need a -f on xfire aswell.

Yes, you would have prefix the file with php -f :P

gamelaster

  • PGP
  • Posts: 29
Re: Basic StdLog parser for statistics/ranking
« Reply #22 on: October 20, 2012, 01:26:27 PM »
pls, who have this script? :/