juman wrote:
Does anyoen have a good tip if there is a module or good way to split a
html file inte header and body? What I want to do is to combine several
htmlfiles into one. And the idea is to remove all headers from all the
files and combine the bodys into a big new one with a new header...

/juman

I've used Mail::Internet in the past in combination with procmail.
Its really simple to use, just have procmail direct the mail to your script and it will parse it as STDIN.
Simple


my $mail = Mail::Internet->new(\*STDIN);
my $headers = $mail->head->header_hashref;
my @body = @{$mail->tidy_body()};
my $SUBJECT = $headers->{Subject}->[0] ;



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to