Re: [Exim] checking for the existence of a string in a strin…

Góra strony
Delete this message
Reply to this message
Autor: Peter Bowyer
Data:  
Dla: exim-users
Temat: Re: [Exim] checking for the existence of a string in a string
Nathan Ollerenshaw <nathan@???> wrote:
> Quick question
>
> In my first router, I do an LDAP lookup and store the result into
> $address_data to avoid doing more lookups for that address again.
>
> If I want to extract the value for a key with a single value, it works
> fine. But, some LDAP attributes exist multiple times, and they are
> represented as "value1, value2, value3" in the $address_data. Example:
> deliveryMode="nombox, forwardonly"
>
> I want to see if forwardonly is set. How do I do that? I don't see any
> 'isin' operator in the documentation. I guess I could use extract ...


Regexp maybe?

$if {match {$address_data} {forwardonly} {1} {0}}

or something similar.

Peter