I'm curious if anyone has an better idea of how to recieve multiple lines of <STDIN> into a single array. For example, I've written a really basic emailer for administrating email lists I'm on. I can get it to recieve single line entries, such as a To: From: CC: etc from <STDIN> with no problem, but haven't yet successfully tried recieving multiple lines of text for the message body. I'm thinking something like what follows, but I'm wondering if anyone sees a problem with this or has a better solution along the same lines.
sub PromptForBody { print ': '; $thisLine = <STDIN>; unless ($thisLine eq ".\n") { push(@messageBody,$thisLine); &PromptForBody; } } I haven't tried the above yet. It's just an idle idea at the moment. For now, I'm just having it open `vi` and then read the contents of the resulting temp file into a scalar value. That works okay for most purposes, but for the shere fun of it, I want to try doing it a little differently. Comments? =================== Shaun Fryer =================== London Webmasters http://LWEB.NET PH: 519-858-9660 FX: 519-858-9024 =================== -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]