my @array=split (/\,/, $aa);
foreach my $elem(@array)
{
    my ($orig)=$elem=~/\<(.*?)\>/i;
    print $orig;
}


Marty

----- Original Message -----
From: "Nolen, Mike" <[EMAIL PROTECTED]>
To: "Perl-Win32-Users Mailing List"
<[EMAIL PROTECTED]>
Sent: Friday, May 19, 2000 5:53 PM
Subject: need help


> I need to return all data inside each set of <> in a string ...
> I've included 2 examples, but they both return the last item only...
> TIA, mike
> -----------------------------
> $aa = "Mike <mike\@mike.com>, Mark <mark\@mark.com>";
> print "$aa\n";
> -- ie. 1
> $aa =~ s/^.*\<(.*)\>.*$/\1/g;
> print "$aa\n";
>
> --ie. 2
> for ( $aa =~ s/^.*\<(.*)\>.*$/\1/g ) {
> print "$aa\n";
> }
>
>
>


---
You are currently subscribed to perl-win32-users as: [archive@jab.org]
To unsubscribe, forward this message to
         [EMAIL PROTECTED]
For non-automated Mailing List support, send email to  
         [EMAIL PROTECTED]

Reply via email to