SRCDS Steam group


Logfile to website
#1
myBB 
Hi guys, tough question here.

I'm wondering(I've never seen it before), if there is a way to print the logfiles of the console to a website in a specific frame. I know how to read a .txt file, and stuff, that works. However I stumble upon 2 problems

1: SRCDS only allows you to write logfiles to the game directory.
2: I don't think I can read a .log file with for example; file_get_contents(in PHP)
I tried linking two files from my /www/ a .txt file to the .log file, that didn't work either.
I am however able to display ping, ip, players etc, any way I can do this for console output?

Is there any other way, or a solution to print the console output to my website?

Reply
#2
I have some logs (not the console log but the principle still applies) that are viewable in the admin section of my website. All I did to achieve this was create a scheduled task (I'm running Windows) to copy and append the log files from the game server logs folder to my www/logs folder.

Its not quite real time (as I don't need that) but it works well enough. Perhaps you could try something like that?
Reply
#3
Possibly, but ideally I want my server to display realtime console logfiles to my websites, anyone else?
Reply
#4
for the ask of anything or anyone else you are better to over web and Google there as no posts yet here .. or you may get a fair clue with the suggestion posted earlier .. as I'm going to get started as per the suggestions there..
Reply
#5
This is possible with ASP/.NET as TCAdmin v2 offers it in their software. I don't know about php though.
Reply
#6
(06-04-2013, 07:42 PM)dosbox Wrote:  Possibly, but ideally I want my server to display realtime console logfiles to my websites, anyone else?

Would an update time of, say, 5 seconds really be to far off real time?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)