Is there a true cross browser solution for shoutcast streams?

时光毁灭记忆、已成空白 提交于 2019-12-04 18:36:34

Since nobody is answering, I ransacked web today and found soundmanager2 - which at least in my tests works fine both on desktop and mobile browsers.

I tested on Android, IOS, on desktop side chrome,firefox,safari and all shoutcast channels seem to work fine.

So here you go :)

http://www.schillmania.com/projects/soundmanager2/

soundManager.setup({
                url: 'soundManager2/swf',
                debugMode: false,
                // optional: use 100% HTML5 mode where available
                // preferFlash: false,
                onready: function() {
                  var mySound = soundManager.createSound({
                    id: 'shoutCast',
                    url: valueSelected+';',
                    type: 'audio/mp3'
                  });
                  mySound.play();
                },
                ontimeout: function() {
                  // Hrmm, SM2 could not start. Missing SWF? Flash blocked? Show an error, etc.?
                }
              });

valueSelected = http://198.27.79.224:9770/

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!