| View previous topic :: View next topic |
| Author |
Message |
trogne
Joined: 09 Dec 2012 Posts: 33
|
Posted: Sat Jun 22, 2013 6:03 pm Post subject: station toggle : listeners adds up!! |
|
|
Hi,
On my website : http://www.aorbaroquethrash.com/
Everytime I toggle the other station, the number of total current listeners is added by one.
That is, the session of the other stream is not deleted.
When I toggle the other station, that one should have 1 listener, and 0 for the previous station.
And toggling again : 0-1, 1-0, and so forth.
This is what's happening now : 1-0, 1-1, 2-1, 2-2, and so forth.
What can I do to 'kill' the listener of the current station when I toggle a the other station ?
Thanks,
Patrick |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sat Jun 22, 2013 8:58 pm Post subject: |
|
|
killing a stream should also flush that sort of thing out but it is not clear what you are doing when you toggle. It sounds like you have an incorrect count bug but I'm unaware of the version you are working with.
karl. |
|
| Back to top |
|
 |
trogne
Joined: 09 Dec 2012 Posts: 33
|
Posted: Sun Jun 23, 2013 3:48 pm Post subject: |
|
|
My Icecast version is 2.3.3-kh5
I just realized that even when I toggle the same station, there's also a new listener added!
When I toggle, I do that : onclick="changestream('stationname')"
function changestream(radio) {
$('#player').load('player.php?radio='+radio);
$('#nowplaying').load('nowplaying.php');
}
The nowplaying.php starts with 'require('icecast.php');
icecast.php gets data from the icecast status page, using php curl.
When I refresh the page, listener are not added.
So, I wonder what exactly needs to be refreshed (I don't want to refresh the entire page).
Maybe browser cache related ?
Thanks for help,
Patrick |
|
| Back to top |
|
 |
trogne
Joined: 09 Dec 2012 Posts: 33
|
Posted: Tue Jul 02, 2013 7:51 pm Post subject: |
|
|
It was related to jPlayer.
I don't have this problem with a normal flash player (too bad that android devices doesn't support flash). |
|
| Back to top |
|
 |
|