$Revision: 1.2 $
$Date: 2005/08/24 13:24:31 $

# Functions

## `enum_query(),enum_query("suffix"), enum_query("suffix","service")`

The function performs an enum query and rewrites the Request-URI with the result of the query. See for more information.

Meaning of the parameters is as follows:

- suffix - Suffix to be appended to the domain name.

- service - Service string to be used in the service field.

### `enum_query` usage

    ...
    # search for "e2u+sip" in freenum.org
    enum_query("freenum.org.");
    ...
    # search for "e2u+sip" in default tree (configured as parameter)
    enum_query();
    ...
    # search for "e2u+voice:sip" in e164.arpa
    enum_query("e164.arpa.","voice");
    ...
    # search for service type "sip" or "voice:sip" or "video:sip"
    # note the '+' sign in front of the second parameter
    enum_query("e164.arpa.","+sip+voice:sip+video:sip");
    ...
    # quering for service sip and voice:sip
    enum_query("e164.arpa.");
    enum_query("e164.arpa.","voice");
    # or use instead
    enum_query("e164.arpa.","+sip+voice:sip");
    ...

## `is_from_user_e164()`

Checks if the user part of from URI an E164 number of the form +[0-9]{2,15}. Returns 1 if yes and -1 if not.

### `is_from_user_e164` usage

    ...
    if (is_from_user_e164()) {
        ....
    };
    ...