rendered paste bodyalias rstitle {
.remove source.html
.sockclose rstitle
.sockopen rstitle www.runescape.com 80
}
ALIAS HTMLStrip {
var %x, %i = $regsub($1-,/(^[^<]*>|<[^>]*>|<[^>]*$)/g,$null,%x), %x = $replace($remove(%x, ),&,&)
return %x
}
on 1:SOCKOPEN:rstitle:{
sockwrite -n rstitle GET /lang/en/aff/runescape/index.ws HTTP/1.0
sockwrite -n rstitle Host: www.runescape.net
sockwrite -n rstitle Connection: Keep-Alive
sockwrite -n rstitle $crlf
}
on 1:SOCKREAD:rstitle:{
.sockread %data
echo -a $iif(%data == $null,-,%data)
if (<title> isin %data) { echo -a $HTMLStrip(%data) }
}