Cheiron commented on a Page, Last.fm Now Playing  -  Mar 05, 2009

you can always try this ...

on *:TEXT:!tune:#radio:{ /songp }
alias songp {
  sockopen songp "url for the website showing what is playing"
  /set %kanaal4 #radio
}
on *:sockopen:songp: {
  sockwrite -n $sockname GET /7 HTTP/1.0
  sockwrite -n $sockname User-Agent: Mozilla
  sockwrite -n $sockname
}
on *:sockread:songp:{
  var %t
  sockread %t
  while ($sockbr) {
    sockread -f %t
    if ($regex(%t,/<body>(.*?)</body>/)) {
      tokenize 44 $regml(1)
      if (%last != $7-) {
      /msg %kanaal4 13,1 Current Song playing on "station" Radio: 15 $7-
      set %last $7-
      }
    }
  }
}
alias stime { .timercheck 0 10 songp }
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.