I have this script that is yours and it works very well, but need to work on multiple channels, you can do?

PS: And in the part where it says: "The streaming is currently offline." He it repeats twice in chat.



alias uptime_chan return

ON *:TEXT:!uptime:#: {
var %c = $chr(35) $+ $uptime_chan
if (%c == $chan) { uptime }
}

alias uptime {
sockclose uptime
sockopen uptime nightdev.com 80
}

ON *:SOCKOPEN:uptime: {
if ($sockerr) { sockclose $sockname | halt }
sockwrite -n $sockname GET /hosted/uptime.php?channel= $+ $uptime_chan HTTP/1.1
sockwrite -n $sockname Host: $sock($sockname).addr
sockwrite -n $sockname $crlf
}

ON *:SOCKREAD:uptime: {
if ($sockerr) { sockclose $sockname }
var %data
sockread %data
if ($gettok(%data,1,32) isnum) && ($gettok(%data,2,32)) {
var %c = $chr(35) $+ $uptime_chan
if ($me !ison %c) { return }
.msg %c The streaming is up for $qt(%data) $+ .
}
elseif (*not live.* iswm %data) {
var %c = $chr(35) $+ $uptime_chan
if ($me !ison %c) { return }
.msg %c The streaming is currently offline.
}
}