Re: [Exim] exim + perl question

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Bradford Carpenter
Date:  
À: exim-users
Sujet: Re: [Exim] exim + perl question
On Mon, 24 May 2004 13:46:01 +0900, Valentin S. Ryabinin wrote:

> following does not work:
> condition =${if eq {${perl{mysub}}} {(?i)Yes}
> {1}{0}}
> also in second part: or {"yes"} or {return "yes"}.
>
>
> i'm confused.


Never had occasion to use the perl expansion, but there are a couple of
ways to do a case-insensitive check on the return value.

condition = ${if eqi {${perl{mysub}}} {yes} {1}{0}}

condition = ${if match {${perl{mysub}}} {\N(?i)yes\N} {yes}{no}}

Either {1}{0} or {yes}{no} or {true}{false} may be used a the end of
the condition statement.

Hope that was an answer to your question!

Best regards,
Brad Carpenter