Results 1 to 15 of 131
Thread: Online Display Script
-
06-01-2003, 18:54 #1
-= TeamSpeak Lover =-
- Join Date
- Aug 2002
- Location
- Haydock
- Posts
- 73
Online Display Script
Is there any way of creating a small script that works similar to ICQ, i.e when the page or script is activated it checks to see if the ts server is online if it is it displays a small online image (green light) if not then displays a red light, or something similar.
Any help appreciated.
-
07-01-2003, 01:45 #2
-= TeamSpeak Lover =-
- Join Date
- Dec 2002
- Location
- ATL, GA
- Posts
- 61
I'm sure this can be done with some php script, but what are you trying to use this on? a website I'm guessing? It would be fairly simple script, and I could get our scripter to write one, but right now I'm giving him the job of getting the info of who is online instead of it the server is online, or I might ask another site that I saw that on if I could borrow thiers...blah...blah...blah...
-
07-01-2003, 08:49 #3
-= TeamSpeak Lover =-
- Join Date
- Aug 2002
- Location
- Haydock
- Posts
- 73
I would like it really just for a standard php page really.
CheersLast edited by Bigman; 07-01-2003 at 12:37.
-
07-01-2003, 15:45 #4
-= TeamSpeak Lover =-
- Join Date
- Dec 2002
- Location
- ATL, GA
- Posts
- 61
I'll see what we can do, but if anyone else wants to try to do this, go for it.
-
12-01-2003, 09:13 #5
-= TeamSpeak Fanatic =-
- Join Date
- Jan 2003
- Location
- Germany
- Posts
- 4,140
i have something for you. it's primitive, but works.
you might need to change some values for your own server, but it should be a good start:
did you notice the biiiig fscanf call? i figured out the first number is the player id and the last string is the player name.PHP Code::p
if you figure out the meanings of the other values i'd be happy if you would share that information.Last edited by Brain; 19-07-2004 at 13:53.
-
12-01-2003, 17:03 #6
-= TeamSpeak User =-
- Join Date
- Jan 2003
- Location
- Ohio
- Posts
- 24
Nice work on the script. However, it times out for me. I'll keep playing around and see what's up with it.
Last edited by Addict; 12-01-2003 at 17:12.
-
12-01-2003, 22:03 #7
-= TeamSpeak Fanatic =-
- Join Date
- Jan 2003
- Location
- Germany
- Posts
- 4,140
1.) the script uses default ports so make sure port 51234 tcp is accessible
2.) the script assumes the teamspeak server is running on the same maching as the webserver. change "localhost" to your teamspeak server's address if necessary
3.) i'm running apache 1.3.27 with php 4.3.0, tss2 and apache run on the same physical machine. the script works for me. see for yourself, i have integrated it into my clan's message board -> http://www.the-rip.de/wbboard
-
12-01-2003, 22:11 #8
-= TeamSpeak User =-
- Join Date
- Jan 2003
- Location
- Ohio
- Posts
- 24
Yeah i got the timeout fixed.
It errors out on the first sendQuery. Almost like its not finding the right response. I'll keep digging though.
I'm running it on the same server as TS & web. I'm running Win2k Server with IIS. PHP 4.3.0.Last edited by Addict; 13-01-2003 at 00:36.
-
13-01-2003, 11:17 #9
-= TeamSpeak Fanatic =-
- Join Date
- Jan 2003
- Location
- Germany
- Posts
- 4,140
i assume it is this line that causes the timeout. hmmm... windoze you say.... maybe it's another case of line break problemsPHP Code:if(getResults($socket) != "OK\n") {
try OK\r\n instead of OK\n, maybe it helps
or you can just telnet to localhost:51234 and test it yourself
-
13-01-2003, 12:23 #10
-= TeamSpeak User =-
- Join Date
- Jan 2003
- Location
- Ohio
- Posts
- 24
No it wasn't that line timing out. It was the initial connection. Got that fixed.Originally posted by Brain
i assume it is this line that causes the timeout. hmmm... windoze you say.... maybe it's another case of line break problemsPHP Code:if(getResults($socket) != "OK\n") {
try OK\r\n instead of OK\n, maybe it helps
or you can just telnet to localhost:51234 and test it yourself
I'll try the OK\r\n and see if that works. Thanks.
-
13-01-2003, 23:57 #11
-= TeamSpeak User =-
- Join Date
- Jan 2003
- Location
- Ohio
- Posts
- 24
Got it.
For windows it does have to the \r
Thanks....
-
14-01-2003, 05:10 #12
-= TeamSpeak User =-
- Join Date
- Aug 2002
- Location
- Oz
- Posts
- 15
I get this error on Linux with php 4.2.2
Internal server error! Cause unknown.
Dont know whyPHP Code:// select the one and only running server on port 8767
sendQuery($socket, "sel 8767");
if(getResults($socket) != "OK\n") {
echo("Internal server error! Cause unknown.");
exit;
}// end if
-
14-01-2003, 12:45 #13
-= TeamSpeak User =-
- Join Date
- Jan 2003
- Location
- Ohio
- Posts
- 24
Did you try adding the \r? Immediately after the OK.Originally posted by direwolf
I get this error on Linux with php 4.2.2
Dont know why
That's just a generic error as this script has no error handling. Also you may want to switch to PHP 4.3.0.PHP Code:// select the one and only running server on port 8767
sendQuery($socket, "sel 8767");
if(getResults($socket) != "OK\r\n") {
echo("Internal server error! Cause unknown.");
exit;
}// end if
-
14-01-2003, 13:00 #14
-= TeamSpeak Fanatic =-
- Join Date
- Jan 2003
- Location
- Germany
- Posts
- 4,140
php before 4.3.0 needs two parameters in the fgets function. -> http://www.php.net/manual/en/function.fgets.php
i'm using php 4.3.0 on a linux webserver with linux tss2. ymmv.
-
14-01-2003, 14:00 #15
-= TeamSpeak Lover =-
- Join Date
- Aug 2002
- Location
- Haydock
- Posts
- 73
Can someone visit this page and see why im getting this error Cheers
http://bigmanrlfans.dyndns.org/listing.php
Im using IIS and PHP 4.3.0
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
New Teamspeak Query script for php: Teamspeak Display
By MrGuide@NL in forum [TeamSpeak 2] Addons & ScriptsReplies: 347Last Post: 06-08-2010, 17:17 -
User Online PHP Script
By 1Aless1 in forum [TeamSpeak 2] Server SupportReplies: 2Last Post: 11-03-2009, 13:20 -
User online - offline script (php)
By crazyandy in forum [TeamSpeak 2] Addons & ScriptsReplies: 2Last Post: 19-03-2007, 17:17 -
php script zum ts server online bestellen/aufschalten gesucht
By noob1986 in forum [TeamSpeak 2] Server SupportReplies: 6Last Post: 27-05-2006, 13:50 -
Teamspeak 2 Status Display Script Released!
By justinkwaugh in forum [TeamSpeak 2] Addons & ScriptsReplies: 6Last Post: 09-02-2006, 09:14


Reply With Quote