comparison xml/en/docs/njs/reference.xml @ 2544:33347df1da9c

Relocated sentence in r.headers.Out, added dot, corrected quotes.
author Yaroslav Zhuravlev <yar@nginx.com>
date Tue, 19 May 2020 15:05:49 +0100
parents f39c4724c0f8
children dca5a7053a6c
comparison
equal deleted inserted replaced
2543:f39c4724c0f8 2544:33347df1da9c
7 <!DOCTYPE article SYSTEM "../../../../dtd/article.dtd"> 7 <!DOCTYPE article SYSTEM "../../../../dtd/article.dtd">
8 8
9 <article name="Reference" 9 <article name="Reference"
10 link="/en/docs/njs/reference.html" 10 link="/en/docs/njs/reference.html"
11 lang="en" 11 lang="en"
12 rev="41"> 12 rev="42">
13 13
14 <section id="summary"> 14 <section id="summary">
15 15
16 <para> 16 <para>
17 <link doc="index.xml">njs</link> provides objects, methods and properties 17 <link doc="index.xml">njs</link> provides objects, methods and properties
98 <para> 98 <para>
99 Field values of multi-value response headers 99 Field values of multi-value response headers
100 (<link doc="changes.xml" id="njs0.4.0">0.4.0</link>) 100 (<link doc="changes.xml" id="njs0.4.0">0.4.0</link>)
101 can be set with the syntax: 101 can be set with the syntax:
102 <example> 102 <example>
103 r.headersOut[‘Foo’] = [‘a’, ‘b’] 103 r.headersOut['Foo'] = ['a', 'b']
104 </example> 104 </example>
105 where the output will be: 105 where the output will be:
106 <example> 106 <example>
107 Foo: a 107 Foo: a
108 Foo: b 108 Foo: b
114 <para> 114 <para>
115 For standard response headers 115 For standard response headers
116 that accept only a single field value such as 116 that accept only a single field value such as
117 <header>Content-Type</header>, 117 <header>Content-Type</header>,
118 only the last element of the array will take effect. 118 only the last element of the array will take effect.
119 Field values of the <header>Set-Cookie</header> response header
120 are always returned as an array.
119 Duplicate field values in 121 Duplicate field values in
120 <header>Age</header>, 122 <header>Age</header>,
121 <header>Content-Encoding</header>, 123 <header>Content-Encoding</header>,
122 <header>Content-Length</header>, 124 <header>Content-Length</header>,
123 <header>Content-Type</header>, 125 <header>Content-Type</header>,
127 <header>Location</header>, 129 <header>Location</header>,
128 <header>Retry-After</header> 130 <header>Retry-After</header>
129 response headers are ignored. 131 response headers are ignored.
130 Duplicate field values in all other response headers 132 Duplicate field values in all other response headers
131 are separated by commas. 133 are separated by commas.
132 Field values of the <header>Set-Cookie</header> response header
133 are always returned as an array.
134 </para> 134 </para>
135 </tag-desc> 135 </tag-desc>
136 136
137 <tag-name><literal>r.httpVersion</literal></tag-name> 137 <tag-name><literal>r.httpVersion</literal></tag-name>
138 <tag-desc> 138 <tag-desc>