patmarbidon schreef:

> Can you try
> if ( $projet =~ /^([EMAIL PROTECTED])@/ ) {
>    $provb = $1
> }
>
> You will collect all characters from the beginnning to the first '@'.
> If The first character is a '@' you will obtain an empty string.
> If the first character is a '@' and you want to exclude this case use
> '^([EMAIL PROTECTED])@ to obtain a result only if there is at least one 
> character
> before the first '@'.

It's  best to escape the @, for example against the (future) existense
of @].

    m{^ ([EMAIL PROTECTED]) [EMAIL PROTECTED]

-- 
Affijn, Ruud

"Gewoon is een tijger."


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to