Go Back   Winamp Forums > SHOUTcast > SHOUTcast Discussions

Reply
Thread Tools Search this Thread Display Modes
Old 5th October 2006, 17:25   #1
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
PHP Script for multiple SHOUTcast servers

Heres a free script that I made that allows you to get the listener number from as many SHOUTcast servers as you like.

It also includes a simple bar chart for each server showing how full it is (hover your mouse over the bar to see percentage) and tells you when there has been an error (server offline or no source)

No more checking each relay to see how many listeners you have - hope someone finds it useful...

Click here to see a demo

Click here to download the file
BELLonline is offline   Reply With Quote
Old 5th October 2006, 18:26   #2
hackerdork
Forum King
 
hackerdork's Avatar
 
Join Date: Feb 2006
Location: Earth Circa sometime.
Posts: 3,297
kinda cool

~ According to the ship's log we're down to our last 3000 vomit bags.It'll never be enough.
search the forums! don't PM me on how-to, or ask me to setup you system. you do it so you learn.
hackerdork is offline   Reply With Quote
Old 5th October 2006, 18:44   #3
AlexIT
Junior Member
 
Join Date: Aug 2006
Location: Italy
Posts: 28
Send a message via ICQ to AlexIT
Wery useful staff, thanx.
AlexIT is offline   Reply With Quote
Old 8th October 2006, 17:50   #4
zee100
Senior Member
 
Join Date: Nov 2003
Location: Germany
Posts: 169
That's a cool script.
I have just one question.
How do I change the color of the bar.gif?
I change the script a little to my needs.
I use a orange background in the listeners graph and the bar.gif is also in that color and a little hard to read/see.

Have a look.
http://www.magic104.longmusic.com/multistats2x.php

If you use Firefox you see only a text and no bar.gif!
zee100 is offline   Reply With Quote
Old 9th October 2006, 10:18   #5
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
Glad people are finding the script useful
BELLonline is offline   Reply With Quote
Old 9th October 2006, 17:39   #6
zee100
Senior Member
 
Join Date: Nov 2003
Location: Germany
Posts: 169
but still don't know how to change the color of the bar.gif.
Any help?
zee100 is offline   Reply With Quote
Old 13th October 2006, 10:36   #7
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
Yes, the bar image is just a 1x1 pixel balck gif image - just change the colour of that. There is also a red one for when the server is at 100% capacity.
BELLonline is offline   Reply With Quote
Old 13th October 2006, 12:51   #8
zee100
Senior Member
 
Join Date: Nov 2003
Location: Germany
Posts: 169
Thanks.
I simply create a bar.gif file and stored that one in the same server folder where the php script is stored.
Worked perfect now.
zee100 is offline   Reply With Quote
Old 13th October 2006, 13:02   #9
RadioRevolt
Member
 
Join Date: Apr 2006
Posts: 99
does this script keep a log? that would be great to keep tabs on which servers are most popular or your compeition
RadioRevolt is offline   Reply With Quote
Old 13th October 2006, 13:10   #10
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
It doesn't but it would be easy to do.

It would just mean logging the info to a database and setting a cron to run the script every x minutes.

I have done a script that gets info from 7.html and logs it, so I might stick the two scripts together at some point.

For long term stats logging, I think Shoutstats is probably a better option.
BELLonline is offline   Reply With Quote
Old 21st October 2006, 13:52   #11
RadioRevolt
Member
 
Join Date: Apr 2006
Posts: 99
i've been using this to take snapshots of my competition throughout the day and night to see how we are doing. I had a thought though, I can't tell what they are playing or doing, is there a way to switch it so that the script will show what song is playing on each one?
RadioRevolt is offline   Reply With Quote
Old 21st October 2006, 13:58   #12
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
The script is designed mainly for monitoring your own relays, hence only getting the title from your first server, but that should be easy enough.


If you find the html code for the table (around lines 189-200) just put <?php print song[$i]; ?> where you want the song to appear.

I haven't tested it but that should work.
BELLonline is offline   Reply With Quote
Old 5th November 2006, 06:17   #13
CraftyNut
Junior Member
 
Join Date: Nov 2006
Posts: 1
Where do you put the file to get this to work.....sorry...im kind of new to this...
CraftyNut is offline   Reply With Quote
Old 5th November 2006, 12:47   #14
BELLonline
Senior Member
 
Join Date: Sep 2006
Location: MixStream.net
Posts: 246
Hi, all you need to do is download the script and extract the files, edit the servers in multi-server-stats.php and upload it to your webspace.
BELLonline is offline   Reply With Quote
Old 5th November 2006, 21:47   #15
Jkey
Forum King
 
Join Date: Jul 2004
Location: E*arth
Posts: 2,979
thanks BELLonline great script


edit: oh its you gav well done

I'm not here right now - leave a msg after the beep...
Jkey is offline   Reply With Quote
Reply
Go Back   Winamp Forums > SHOUTcast > SHOUTcast Discussions

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump