[buug] Perl question
Will Lowe
harpo at thebackrow.net
Thu Oct 16 00:05:21 PDT 2003
I'm not sure I understand your question.
> ($email,$itemcategory,$subject,$adtype,$picurl,$adindex,$descrip,$datenum) = split(/###/,$pre);
Something like
my @array = split(/###/, $pre);
Or do you want a function to repeat this line of code ... in which
case I suggest:
sub getdata( $ ) {
my $input = shift;
my @array = split(/###/, $input);
return @array;
}
Which would be used like this:
my @array = getdata($pre);
--
thanks,
Will
More information about the buug
mailing list