<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"><channel><title>th1nk - Latest Comments in How to pull statistics from Icecast with PHP</title><link>http://th1nk.disqus.com/</link><description>Web Concepts and Analysis </description><language>en</language><lastBuildDate>Thu, 13 Nov 2008 04:58:10 -0000</lastBuildDate><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-3736577</link><description>Oh and also, if you could help with another problem I would greatly appreciate it.&lt;br&gt;icestats.php seems to produce an error - I believe - whenever the current song has scandinavian characters in its name (like å,ä,ö). I found out that the reason is SimpleXML can only output utf-8... possibly. I was just wondering if there was some way stop this error from happening.&lt;br&gt;&lt;br&gt;Thanks again</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jass</dc:creator><pubDate>Thu, 13 Nov 2008 04:58:10 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-3735413</link><description>How should I actually go with getting stats from all mountpoints? Because the demo expects that I just want to access /pirate-radio's stats. How do I get all the mountpoints so I can $r-&amp;gt;check_station($mountpoint) them.&lt;br&gt;&lt;br&gt;Thanks</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jass</dc:creator><pubDate>Thu, 13 Nov 2008 04:41:47 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-3056296</link><description>I forgot to mention... I using PHP 5.2.3</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Marcio</dc:creator><pubDate>Tue, 14 Oct 2008 21:04:11 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-3055447</link><description>HI!&lt;br&gt;&lt;br&gt;I can not to manage it to work. See the error... How can I fix it?&lt;br&gt;&lt;br&gt;Warning: Call-time pass-by-reference has been deprecated; If you would like to pass it by reference, modify the declaration of fsockopen(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. in /home/mslino/atcbsb.com.br/icestats.php on line 16 Warning: Call-time pass-by-reference has been deprecated; If you would like to pass it by reference, modify the declaration of fsockopen(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. in /local/home/mslino/atcbsb.com.br/icestats.php on line 16 Warning: fsockopen(): unable to connect to atcbsb.com:8000 (Connection timed out) in /local/home/mslino/atcbsb.com.br/icestats.php on line 16 Warning: fputs(): supplied argument is not a valid stream resource in /local/home/mslino/atcbsb.com.br/icestats.php on line 25 Warning: fgets(): supplied argument is not a valid stream resource in /local/home/mslino/atcbsb.com.br/icestats.php on line 26 Warning: fclose(): supplied argument is not a valid stream resource in /local/home/mslino/atcbsb.com.br/icestats.php on line 27 The requested station is currently unavailable.&lt;br&gt;&lt;br&gt;Thanks!</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Marcio</dc:creator><pubDate>Tue, 14 Oct 2008 20:46:58 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-1602002</link><description>Thanks for the code. &lt;br&gt;&lt;br&gt;I am totally new to PHP and found that it wouldn't run at first on my hosting company's server (which is running PHP 5). I found that I needed to change the line&lt;br&gt;&lt;br&gt;require_once('icestats.php');&lt;br&gt;&lt;br&gt;in the example page to&lt;br&gt;&lt;br&gt;include 'icestats.php';&lt;br&gt;&lt;br&gt;Otherwise I got a 'class declared twice' error or something like that.&lt;br&gt;&lt;br&gt;Also for those people like me who don't have a clue how to extract individual fields from the returned object, after a bit of trial and error (!) it turns out you can do it like this:&lt;br&gt;&lt;br&gt;For example, to print the current artist:&lt;br&gt;&lt;br&gt;echo $stats-&amp;gt;artist[0];&lt;br&gt;&lt;br&gt;Basically change 'artist' above for whatever other field your are interested in..&lt;br&gt;&lt;br&gt;Thanks again for sharing your code - &lt;br&gt;Matt</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Matt Ford</dc:creator><pubDate>Fri, 01 Aug 2008 06:00:58 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-1602003</link><description>hi john&lt;br&gt; &lt;br&gt;it works very fine. now can i read all parameter in every mount point. thanks.&lt;br&gt;&lt;br&gt;holger</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">huelgueuer</dc:creator><pubDate>Thu, 05 Jun 2008 11:56:32 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-1602005</link><description>Hey huelgueuer:&lt;br&gt;&lt;br&gt;I actually haven't tested this with multiple mount points - I just threw it together for a station I run in my personal time, so let me play with it a bit and see what I can come up with.&lt;br&gt;&lt;br&gt;As to the IP address listings, if you do a print_r($stats) on the array returned back from the get_parsed_stats() function, you'll see what fields you have available for output - listener count and such are available, but I don't see a way off-hand to get the IP addresses of listeners.  It would probably entail parsing another one of the XML files on the server, but like I said, this was just a quick thing I threw together, so I'm not sure.&lt;br&gt;&lt;br&gt;I'll take a look and see what I can come up with for both issues, here, and post back.&lt;br&gt;&lt;br&gt;- John</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">John Galvin</dc:creator><pubDate>Tue, 03 Jun 2008 22:15:33 -0000</pubDate></item><item><title>Re: How to pull statistics from Icecast with PHP</title><link>http://www.th1nk.com/code/how-to-pull-statistics-from-icecast-with-php/#comment-1602004</link><description>hi&lt;br&gt;&lt;br&gt;it works fine, but we have 5 mountpoints in the stats&lt;br&gt;/48&lt;br&gt;/96&lt;br&gt;/128&lt;br&gt;/dump&lt;br&gt;/live&lt;br&gt;&lt;br&gt;the listeners in the script comes from /live&lt;br&gt;how can i change to /128 ?&lt;br&gt;&lt;br&gt;and can i list ips from&lt;br&gt;&lt;br&gt;&lt;a href="http://......../admin/listclients.xsl?mount=/128" rel="nofollow"&gt;http://......../admin/listclients.xsl?mount=/128&lt;/a&gt;&lt;br&gt;&lt;br&gt;mfg&lt;br&gt;&lt;br&gt;huelgueuer</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">huelgueuer</dc:creator><pubDate>Tue, 03 Jun 2008 21:59:58 -0000</pubDate></item></channel></rss>