Because you're using the POST method the variables shouldn't be appended to the URL, instead they should be URL encoded and sent after the headers as the message body. The length of all those variables in a string (ie. the message body length) should be sent as the Content-Length header. The Content-Type header should be application/x-www-form-urlencoded (unless the form explicitly provides a different one, which that form doesn't). The From header isn't necessary. The User-Agent header isn't technically necessary but some CGI scripts don't like it if you don't provide one. You should also specify Host and Referer headers to be safe.

Code:
alias urlencode return $replace($regsubex($1,/([^\w\d\x20])/g,% $+ $base($asc(\t),10,16)), $chr(32), +)



; Socket code starts here

var %message = search= $+ $urlencode($1) $+ &max=10&exact=true&from=English&to=Latin&fname=eng2lat1&back=lat.html

sockwrite -n moo POST /onldict/onldict.php HTTP/1.0
sockwrite -n moo Host: www.freedict.com
sockwrite -n moo User-Agent: Anything
sockwrite -n moo Referer: http://www.freedict.com/onldict/lat.html
sockwrite -n moo Content-Type: application/x-www-form-urlencoded
sockwrite -n moo Content-Length: $len(%message)
sockwrite -n moo
sockwrite -t moo %message



Spelling mistakes, grammatical errors, and stupid comments are intentional.