Hi Punit,

>           /ldap:\/\/\/(.+)|mailto:(.+)/;
> When i run this I get  uid=user1,ou=People,o=test.com <http://test.com/> as 
> output however don't get y...@gmail.com <mailto:y...@gmail.com> printed.
> 

The mailto is matched by $2, not $1. You can confirm this by changing your 
print line to:

        print $1 // $2, "\n";

Another suggestion: the regex is easier to read if you use a different regex 
delimiter:

        m!ldap:///(.+)|mailto:(.+)!;

Cheers,
Neil

Reply via email to