Jump to content

Latency script


dimitrifrom31

Recommended Posts

Hi,

 

as title says I was wondering if some1 had a script to show your latency with some server/game server on a web page.

 

Exemple when customers go onto your webpage they can see what their ping would aproximatively be if they were playing on one of your game servers.

 

the script would ping a machine or a gameserver, and returns the latency time that would be showed on the web page.

 

 

 

Thx in advance if sum1 can share it :)

Link to comment
Share on other sites

Well i finally found out some info thx to ur post as i could google with more accuracy some terms :)

 

I made my own php script inspired by what I could find on the web and editing it to my own needs.

 

I put it in attached file if suM1 else interested

 

 

Just upload it into a folder like "ping" on the server you wana ping (it requires it to be a web server supporting php of course). Then use another php page located on the same web server and make an include inside :

 

<? php include("ping/index.php"); ?>

 

you will get the result in millisecond or if firewall enabled a message will tell you "firewall detected".

 

You can see the result on my web : http://www.roxservers.com/gameservers.php

php-ping_3694.zip

Link to comment
Share on other sites

ok here is my second version you can still see it on my web

 

On this version clients will have to push a button so start pinging. This gives 2 advantages :

- if they got a firewall blocking the ping, the page were the script is installed will not take 4 seconds to load anymore. Only the script will take 4 seconds to return the "firewall detected" result.

- if clients ping on purpose they make more chances to turn off their background-bandwidth-wasting applications and so not get afraid by an unexpected high ping :)

 

Also includes french and spanish version. You can easily customize it to fit better with your page and needs.

ping.zip

Link to comment
Share on other sites

  • 1 year later...
neither of these scripts works for me, any other scripts i can try?

 

I have one, and its an olde one back from the dead that ECF probably hasn't seen in, 5 or so years ;)

 

If dimitri wouldnt mind, got this from a really old but good friend over at Fat Pipe.

 

basically put this on your master server and then you can do a ping from your master server and have it just pop up a little box on your clients screen.

 

All you need to do is upload the pingtest.aspx to the root /web directory in tcadmin and this will work =]

 

this is my code on my website:

<a target="foo" onclick="window.open('<your master server without the carrots>/pingtest.aspx?serverid=<the server you want to test ping on TCID without the carrots>', 'foo', 'width=695,height=200,status=yes,resizable=no,scrollbars=no')" />

 

for example

<a target="foo" onclick="window.open('http://192.168.10.1/pingtest.aspx?serverid=masterserver', 'foo', 'width=695,height=200,status=yes,resizable=no,scrollbars=no')" />

 

have issues or problems let me know.

 

Jeremiah

pingtest.zip

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Terms of Use