Skip to content
it4e edited this page Apr 16, 2016 · 2 revisions

Name

<chl/chl.h>

chl_get_header, CHL get header

Declaration

char * chl_get_header(char * name);

Description

The chl_get_header function is used to get the header associated with the [name].

Arguments

  • name: the name of the header

Return value

Header value, or 0 if header is not defined.


Examples

main.c

#include <chl/chl.h>
#include <stdio.h>

int main() {
    char * val;
    
    chl_set_header("x-test", "test header");
    val = chl_get_header("x-test");
    
    fputs(val, stdout);
}

Output: test header

As CHL is open-source, people are able to contribute with their own APIs, plugins and code which means that CHL is constantly upgraded and provided with new features. Do you have an idea for a new CHL feature and want to contribute?

See contribute.

Setup. API. Tutorial. Examples. FastCGI.

Clone this wiki locally