[thelist] foreach problem with Perl

Niklaus Haldimann runciter at rosa.com
Mon Jul 23 04:39:31 CDT 2001


Tony Grimes wrote:
> I need some perl help. I'm writing a script to automate multiple
> majordomo subscriptions from a web form by sending an email using
> sendmail. Everything's working fine except that an extra space is added at
> the beginning of some of the lines in the final email (actually, every one
> after the first line).

Lists are by default separated by a space when printing them like you
do. The separator is stored in the special variable $". Add

$"='';

to your script before you print out the @lists array.

Cheers,
N.

--
Niklaus Haldimann, Frontend Engineer
At Work: http://www.rosa.com
At Play: http://www.ubique.ch
--
log-power to the WAP-people: http://www.waplog.ch




More information about the thelist mailing list