1 <?xml version="1.0" encoding='ISO-8859-1'?>
2 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
5 <!-- Include general documentation entities -->
6 <!ENTITY % docentities SYSTEM "../../../../doc/docbook/entities.xml">
10 <!-- Module User's Guide -->
14 <title>&adminguide;</title>
17 <title>Overview</title>
19 The module exports utility functions to work with position inside the
23 Among them are function to add or remove content at a specific position.
27 <title>Dependencies</title>
29 <title>&kamailio; Modules</title>
31 The following modules must be installed (but not loaded) to use this module:
35 <emphasis>none</emphasis>.
42 <title>External Libraries or Applications</title>
44 The following libraries or applications must be installed before running
45 &kamailio; with this module loaded:
49 <emphasis>none</emphasis>.
58 <title>Functions</title>
59 <section id="posops.f.pos_append">
61 <function moreinfo="none">pos_append(idx, val)</function>
64 Append the value val after the position idx in the SIP message buffer.
67 The idx can be an integer value or a variable holding an integer. If
68 the value is negative, the position is counted from the end of the buffer.
71 The val can be a static string or variables.
74 This function can be used from ANY_ROUTE.
77 <title><function>pos_append()</function> usage</title>
78 <programlisting format="linespecific">
80 pos_append("100", "kamailio-$si");
85 <section id="posops.f.pos_insert">
87 <function moreinfo="none">pos_insert(idx, val)</function>
90 Insert the value val at the position idx in the SIP message buffer.
93 The idx can be an integer value or a variable holding an integer. If
94 the value is negative, the position is counted from the end of the buffer.
97 The val can be a static string or variables.
100 This function can be used from ANY_ROUTE.
103 <title><function>pos_insert()</function> usage</title>
104 <programlisting format="linespecific">
106 pos_insert("100", "kamailio-$si");
111 <section id="posops.f.pos_rm">
113 <function moreinfo="none">pos_rm(idx, len)</function>
116 Remove len characters starting at the position idx in the SIP message buffer.
119 The idx can be an integer value or a variable holding an integer. If
120 the value is negative, the position is counted from the end of the buffer.
123 The idx can be a positive integer value or a variable holding a positive
127 This function can be used from ANY_ROUTE.
130 <title><function>pos_rm()</function> usage</title>
131 <programlisting format="linespecific">
133 pos_insert("100", "10");