---
name: "httpd_conf"
section: "3erl"
platform: "linux"
package: "erlang-manpages"
version: "1:17.3-dfsg-4+deb8u2"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/httpd_conf"
---

# httpd\_conf(3erl)

Configuration utility functions to be used by the Erlang Web server API programmer.

## NAME

httpd\_conf - Configuration utility functions to be used by the Erlang\
     Web server API programmer.

## DESCRIPTION

This module provides the Erlang Webserver API programmer with utility functions for adding run-time configuration directives.

## EXPORTS

**check\_enum(EnumString, ValidEnumStrings) -\> Result**\

Types:

EnumString = string()\
 ValidEnumStrings = \[string()\]\
 Result = {ok,atom()} \| {error,not\_valid}\

*check\_enum/2* checks if *EnumString* is a valid enumeration of *ValidEnumStrings* in which case it is returned as an atom.

**clean(String) -\> Stripped**\

Types:

String = Stripped = string()\

*clean/1* removes leading and/or trailing white spaces from *String*.

**custom\_clean(String,Before,After) -\> Stripped**\

Types:

Before = After = regexp()\
 String = Stripped = string()\

*custom\_clean/3* removes leading and/or trailing white spaces and custom characters from *String*. *Before* and *After* are regular expressions, as defined in *[regexp(3erl)](/regexp/3erl.md)*, describing the custom characters.

**is\_directory(FilePath) -\> Result**\

Types:

FilePath = string()\
 Result = {ok,Directory} \| {error,Reason}\
 Directory = string()\
 Reason = string() \| enoent \| eaccess \| enotdir \| FileInfo\
 FileInfo = File info record\

*is\_directory/1* checks if *FilePath* is a directory in which case it is returned. Please read *[file(3erl)](/file/3erl.md)* for a description of *enoent*, *eaccess* and *enotdir*. The definition of the file info record can be found by including *file.hrl* from the kernel application, see [file(3erl)](/file/3erl.md).

**is\_file(FilePath) -\> Result**\

Types:

FilePath = string()\
 Result = {ok,File} \| {error,Reason}\
 File = string()\
 Reason = string() \| enoent \| eaccess \| enotdir \| FileInfo\
 FileInfo = File info record\

*is\_file/1* checks if *FilePath* is a regular file in which case it is returned. Read *[file(3erl)](/file/3erl.md)* for a description of *enoent*, *eaccess* and *enotdir*. The definition of the file info record can be found by including *file.hrl* from the kernel application, see [file(3erl)](/file/3erl.md).

**make\_integer(String) -\> Result**\

Types:

String = string()\
 Result = {ok,integer()} \| {error,nomatch}\

*make\_integer/1* returns an integer representation of *String*.

## SEE ALSO

**[httpd(3erl)](/httpd/3erl.md)**
