Module ngx_http_addition_module

nginx


english
עברית
日本語
русский
türkçe

news

about
download
security advisories
documentation
introduction
pgp keys
howto
faq
trac
wiki
links
books
support
donation
nginx.com
@nginxorg
Example Configuration
Directives
     add_before_body
     add_after_body
     addition_types

The ngx_http_addition_module module is a filter that adds a text before and after a response. This module is not built by default, it should be enabled with the --with-http_addition_module configuration parameter.

Example Configuration

location / {
    add_before_body /before_action;
    add_after_body  /after_action;
}

Directives

syntax: add_before_body uri;
default:
context: location

Adds a text returned as a result of processing a given subrequest, before the response body.

syntax: add_after_body uri;
default:
context: location

Adds a text returned as a result of processing a given subrequest, after the response body.

syntax: addition_types mime-type ...;
default:
addition_types text/html;
context: http, server, location

This directive appeared in version 0.7.9.

Allows to add text in responses with the specified MIME types, in addition to “text/html”.