Frequently asked questions
How can I display metadata (artist and track name) information with Muses?
Muses has two ways of displaying metadata:
1) Inside the player
2) Passing metadata information to you using a javascript callback event (read how to enable jsEvents here)
On both cases, you first need to enable the metadata fetching fetching by adding the option 'metadataMode' parameter to your code. This option may have one of two possible values 'icecast' or 'shoutcast' depending on your streaming server.
Here is an example on how to set this option for a shoutcast server:
MRP.insert({ 'url':'http://192.241.214.243:9020/;', 'codec':'mp3', 'volume':65, 'autoplay':true, 'buffering':5, 'metadataMode':'shoutcast', // <-- Add this line 'title':'Radio Vermont', 'welcome':'WELCOME TO...', 'bgcolor':'#FFFFFF', 'skin':'mcclean', 'width':166, 'height':83 });
Once you've done this, muses will try to get metadata information for your station every 20 seconds. If you want to change that value, you can add the 'metadataInterval' option like this:
'buffering':5, 'metadataMode':'shoutcast', 'metadataInterval': 15, // <-- Add this line for 15 seconds 'title':'Radio Vermont',
Be advised We strongly recommend that you never set this to a value lower than 10 seconds (setting this value to low, can saturate your streaming server if you have many simultaneous listeners).
Finally, if you're using an old streaming server, there's the chance that cross-domain restrictions avoid muses to grab metadata from your server. If this is the case (you may be able to see cross-domain errors on your browser console log), you may need to use a 'metadataProxy' option. This option allows you to set the URL of some endpoint on your server (made in PHP, NodeJS, Python or any language you like) were muses will call to get the metadata information.
Here's a really basic sample on how to implement that endpoint in PHP: proxy.php sample GitHub
Be advised: Don't use this sample as is. You must add some validation to the URL get parameter (or you'll end up creating an open proxy to malicious users).
More FAQs
- What is Muses Radio Player?
- What do I need to use Muses Radio Player?
- How can I put Muses Radio Player on my blog?
- I already have my streaming URL, how can I install Muses Radio Player on my site?
- I don't have a streaming provider... Where can I get one?
- I have the streaming URL, but Muses isn't working for me: What should I check?
- The audio cuts every few seconds. What's happening?
- When I use OGG audio, it sounds stretchy/pitched. What's happening?
- I've installed crossdomain.xml, but I'm still getting "Security Error" Message. What should I check?
- How does Muses handles memory consumption and audio cache?
- Does Muses Radio Player sends any information concerning my site to any other site?
- I can't find my language listed in Muses Radio Player. What can I do?
- How can I enable Callbacks to get Muses events via Javascript?
- What should I use Event Callbacks for?
- I'm using shoutcast, and I'm quite sure everything is well configured, but my streaming still wont play. What can I try?
- What's a fallback streaming and how can I use this feature?
- What does metadata means?
- I'm using AAC codec but it sounds really bad, and sometimes it doesn't even sound at all.
What should I check? - I've placed the generated HTML code into my .html file, but when I open this file on my browser directly from my hard-drive I don't see the player: What's happening?
- How can I make my own Skin for Muses Radio Player?
- How can I make sure my player works on every browser?
- I provide streaming services: Can I place a Muses setup form on my site?
- How can I display metadata (artist and track name) information with Muses?