on *:text:!Wiki *:#: { if ( !$2 ) { notice $nick 5,5 5,0You did not type what you wished to search for5,5 } else { set %tmp $2- /sockopen WikiSock en.wikipedia.org/wiki 80 } } on *:sockopen:WikiSock:{ /sockwrite -n $sockname GET / $+ %tmp HTTP/1.1 /sockwrite -n $sockname Host: WikiSock en.wikipedia.org/wiki $+ $crlf $+ $crlf } on *:sockread:WikiSock:{ if ($sockerr) { echo -a Error. halt } else { var %temptext sockread %temptext if (
*
iswm %temptext) /msg $chan $htmlfree(%temptext) sockclose $WikiSock unset %tmp } } alias -l htmlfree { var %x, %i = $regsub($1-,/(^[^<]*>|<[^>]*>|<[^>]*$)/g,$null,%x), %x = $remove(%x, ) return %x }