|
How to display current Song in Icecast, the Simple Way. Insert the Icecast Status page in an iframe, cut the desired part and refresh it every xx seconds. Code below.
Important Update: For Icecast with many mount points use the link of type streamurl:port/status.xsl?mount=/yourmountpoint
Code:The "refresher" script. 20000 for 20 seconds
<script type="text/javascript">
setInterval(refreshIframe2, 20000);
function refreshIframe2() {
var frame = document.getElementById("Frame2");
frame.src = frame.src;
}
</script>
The iframe. Here works for the first mount point.
<div style="border: 3px solid rgb(201 , 0 , 1); margin: 15px auto; max-width: 280px; overflow: hidden;">
<iframe id="Frame2" scrolling="no" src="https://funkturm.radio-zusa.net:8443/" style="border: 0px none; height: 900px; margin-left: -0px; margin-top: -800px; width: 280px;">
Replace the address in red with your desired radio address.
Open the radio's status page using its address and port, in a browser. Here is https://funkturm.radio-zusa.net:8443
Height mines margin top gives the real height of the frame, here 100px.
Margin left cuts the left end of the iframe and width gives how wide you need your frame.
Thanks for visiting.