ON $*:TEXT:/^[@!.]weather/Si:#: { Set %postcode $replace($2-,$chr(32),+) set %output $iif($left($1,1) == @, msg $chan, notice $nick) sockopen weather bbc.co.uk 80 } ON *:SOCKOPEN:weather: { sockwrite -nt $sockname GET /cgi-perl/weather/search/new_search.pl?search_query= $+ %postcode HTTP/1.1 sockwrite -nt $sockname Host: uk.weather.com sockwrite -nt $sockname $crlf } ON *:SOCKREAD:weather: { var %read sockread %read if (BBC - Weather Centre - 5 Day Forecast in Celsius for *, * iswm %read) { tokenize 45 %read set %name $remove($1-,BBC, -, Weather, Centre, 5, Day, Forecast, in, Celsius, for) } } ON *:SOCKCLOSE:weather: { %output [WEATHER] Location: %name unset %postcode unset %output unset %name }