use LWP::UserAgent; my $ua = new LWP::UserAgent; # create data my $data = <<"START" ; sum 1.12 4.12 START my $header = <<"START" ; POST /quotes.cgi HTTP/1.0 Host: localhost Content-Type: text/xml START $header .= "Content-length: " . length($data) ; my $content = $header. "\n" . $data ; print $content ; my $response = $ua->post('http://localhost:8999', $content) ; print $response->content;