Browse code

textopsx: docs - notes about 1-based indexing for hf value functions

- GH #2387

Daniel-Constantin Mierla authored on 31/03/2021 14:05:52
Showing 1 changed files
... ...
@@ -205,7 +205,8 @@ if(fnmatch("$rU", "123*"))
205 205
 	<itemizedlist>
206 206
 	    <listitem>
207 207
 		<para><emphasis>hf</emphasis> - Header field to be appended. Format: HFNAME [ [IDX] ].
208
-		If index is not specified new header is inserted at the end of message.
208
+		If index is not specified new header is inserted at the end of message. The index 1
209
+		correxponds to the first header.
209 210
 		</para>
210 211
 	    </listitem>
211 212
 	    <listitem>
... ...
@@ -238,7 +239,8 @@ append_hf_value("foo[-1]", "$var(Bar)") # try add value to the last header, if n
238 239
 	<itemizedlist>
239 240
 	    <listitem>
240 241
 		<para><emphasis>hf</emphasis> - Header field to be appended. Format: HFNAME [ [IDX] ].
241
-		If index is not specified new header is inserted at the top of message.
242
+		If index is not specified new header is inserted at the top of message. The index 1
243
+		correxponds to the first header.
242 244
 		</para>
243 245
 	    </listitem>
244 246
 	    <listitem>
... ...
@@ -269,7 +271,8 @@ insert_hf_value("foo[1]", "gogo") # try add to the first header
269 271
 	<itemizedlist>
270 272
 	    <listitem>
271 273
 		<para><emphasis>hf_par</emphasis> - Header field/param to be removed. Format: HFNAME [ [IDX] ] [. PARAM ]
272
-		If asterisk is specified as index then all values are affected.
274
+		If asterisk is specified as index then all values are affected. The index 1
275
+		correxponds to the first header.
273 276
 		</para>
274 277
 	    </listitem>
275 278
 	</itemizedlist>
... ...
@@ -299,7 +302,8 @@ remove_hf_value("foo[*].bar") # for each foo delete bar parameters
299 302
 	<itemizedlist>
300 303
 	    <listitem>
301 304
 		<para><emphasis>hf_par</emphasis> - Header/param to be removed. Format: HFNAME [ [IDX] ] [. PARAM ]
302
-		If asterisk is specified as index then all values are affected.
305
+		If asterisk is specified as index then all values are affected. The index 1
306
+		correxponds to the first header.
303 307
 		</para>
304 308
 	    </listitem>
305 309
 	</itemizedlist>
... ...
@@ -329,7 +333,8 @@ remove_hf_value2("foo[*].bar") # for each foo delete bar parameters
329 333
 	    <listitem>
330 334
 			<para><emphasis>hf_para</emphasis> - Header field value / param to be appended.
331 335
 				Format: HFNAME [ [IDX] ] [. PARAM]
332
-		If asterisk is specified as index then all values are affected.
336
+		If asterisk is specified as index then all values are affected. The index 1
337
+		correxponds to the first header.
333 338
 		</para>
334 339
 	    </listitem>
335 340
 	    <listitem>
... ...
@@ -365,7 +370,8 @@ assign_hf_value("foo[*].bar", "")  # set empty value (ex. lr)
365 370
 	<itemizedlist>
366 371
 	    <listitem>
367 372
 		<para><emphasis>hf_para</emphasis> - Header field value / param to be appended. Format: HFNAME [ [IDX] ] [. PARAM]
368
-		If asterisk is specified as index then all values are affected.
373
+		If asterisk is specified as index then all values are affected. The index 1
374
+		correxponds to the first header.
369 375
 		</para>
370 376
 	    </listitem>
371 377
 	    <listitem>