2018-02-13 06:16:46 +11:00
var r = document . getElementById ( "radio" ) ;
function Rtoggle ( ) {
if ( $ ( "#radio" ) . hasClass ( "play" ) ) {
Rstop ( ) ;
} else {
$ ( "#radio-view" ) . toggleClass ( "hide" ) ;
2018-02-25 02:59:53 +11:00
$ ( "#radio-view" ) . toggleClass ( "show" ) ;
2018-02-13 06:16:46 +11:00
$ ( "#radio-input" ) . addClass ( "hide" ) ;
}
}
function Rplay ( url , name ) {
$ ( "#radio" ) . attr ( 'src' , url ) ;
r . load ( ) ;
r . play ( ) ;
$ ( "#radio" ) . addClass ( "play" ) ;
$ ( "#radio-btn" ) . addClass ( "teal-text" ) ;
$ ( "#radio-sta" ) . html ( "<br>Now Playing:" + name ) ;
}
function Rstop ( ) {
$ ( "#radio" ) . attr ( "src" , "" ) ;
r . pause ( ) ;
$ ( "#radio" ) . removeClass ( "play" ) ;
$ ( "#radio-btn" ) . removeClass ( "teal-text" ) ;
$ ( "#radio-sta" ) . html ( "" ) ;
}
function Ryourself ( ) {
$ ( "#radio-input" ) . removeClass ( "hide" ) ;
$ ( "#radio-view" ) . addClass ( "hide" ) ;
}
function Rselect ( ) {
$ ( "#radio-input" ) . addClass ( "hide" ) ;
$ ( "#radio-view" ) . removeClass ( "hide" ) ;
}
function Rinput ( ) {
var url = $ ( "#radio-url" ) . val ( ) ;
Rplay ( url , url )
2018-05-02 14:14:03 +10:00
}
/ *
< span id = "radio-sta" class = "radio" > < / s p a n >
< div id = "radio-view" class = "hide radio mize" >
< a onclick = "nowplaying('spotify')" class = "pointer" title = "Ctrl+Shift+N" > < i class = "fa fa-spotify" > < / i > N o w P l a y i n g < / a >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('https://listen.moe/stream','Listen.moe')" data - name = "Listen.moe" > Listen . moe < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://itori.animenfo.com:443/;','AnimeNfo Radio')" data - name = "AnimeNfo Radio" > AnimeNfo Radio < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://hyades.shoutca.st:8043/stream','LoFi hip hop Radio')" data - name = "LoFi hip hop Radio" > LoFi hip hop Radio < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://89.16.185.174:8004/stream','Linn Classical')" data - name = "Linn Classical" > Linn Classical < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://89.16.185.174:8000/stream','Linn Jazz')" data - name = "Linn Jazz" > Linn Jazz < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://edge-ads-01-cr.sharp-stream.com/jazzfmmobile.aac','Jazz FM')" data - name = "Jazz FM" > Jazz FM < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Rplay('http://91.121.59.45:10024/stream','canal-jazz.eu')" data - name = "canal-jazz.eu" > canal - jazz . eu < / s p a n >
< span class = "cbadge pointer waves-effect" onclick = "Ryourself()" > Others < / s p a n >
< / d i v >
< div id = "radio-input" class = "hide radio mize" >
< input type = "url" id = "radio-url" placeholder = "URL" style = "width:100px" >
< button class = "btn waves-effect" onclick = "Rinput()" > Play < / b u t t o n >
< button class = "btn waves-effect" onclick = "Rselect()" > Presets < / b u t t o n >
< / d i v >
* /