alias irct { sockopen irct forums.mirc.com 80 }
on 1:sockopen:irct:{
.sockwrite -n irct GET /ubbthreads.php?ubb=postlist&Board=5 HTTP/1.1
.sockwrite -n irct HOST: forums.mirc.com
.sockwrite -n irct $crlf
}
on 1:sockread:irct:{
if ($sockerr > 0) return
var %x | sockread %x
if ($sockbr == 0) return
if (%x == $null) { return 2 }
if ($regex(%x,/(&|[u,U]ser)/g) == 2) {
if ($regex(%x,/(&|[u,U]user|Post)/g) == 3) { %irct = 8,1 $+ $+([,$nhtml(%x),]) $+ }
if ($regex(%x,/(class|small)/g) == 2) { %irct = %irct 15,1was created 8,1 $+ $nhtml(%x) $+ }
if (small !isin %x) && (nofollow isin %x) { %irct = %irct 15,1 $+ and 8,1 $+ $nhtml(%x) 15,1 $+ was the last person to post. | echo -a %irct }
}
}
alias -l nhtml { return $remove($regsubex($1-,/(^[^<]*>|<[^>]*>|<[^>]*$)/g,),$chr(9)) }