Module: kamailio
Branch: master
Commit: 257cfe9be9327054fb381a48df9605444ea8e6fd
URL:
https://github.com/kamailio/kamailio/commit/257cfe9be9327054fb381a48df96054…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2024-01-08T12:25:32+01:00
siputils: docs for contact_param_check() function
---
Modified: src/modules/siputils/doc/siputils_admin.xml
---
Diff:
https://github.com/kamailio/kamailio/commit/257cfe9be9327054fb381a48df96054…
Patch:
https://github.com/kamailio/kamailio/commit/257cfe9be9327054fb381a48df96054…
---
diff --git a/src/modules/siputils/doc/siputils_admin.xml
b/src/modules/siputils/doc/siputils_admin.xml
index d2197b1c3f4..ad30a1a9f6e 100644
--- a/src/modules/siputils/doc/siputils_admin.xml
+++ b/src/modules/siputils/doc/siputils_admin.xml
@@ -1372,6 +1372,35 @@ if (is_method("REGISTER") and src_ip == 1.2.3.4) {
contact_param_rm("myparam");
}
...
+</programlisting>
+ </example>
+ </section>
+ <section id="siputils.f.contact_param_check">
+ <title>
+ <function moreinfo="none">contact_param_check(pname)</function>
+ </title>
+ <para>
+ This function returns true (1) if the URI inside the Contact
+ header contains the parameter with the name 'pname'. Otherwise it
+ returns false (-1).
+ </para>
+ <para>Meaning of the parameters is as follows:</para>
+ <itemizedlist>
+ <listitem>
+ <para><emphasis>pname</emphasis> - name of the URI parameter.
+ </para>
+ </listitem>
+ </itemizedlist>
+ <para>
+ This function can be used from ANY_ROUTE.
+ </para>
+ <example>
+ <title><function>contact_param_check</function> usage</title>
+ <programlisting format="linespecific">
+...
+if (contact_param_check("myparam")) {
+}
+...
</programlisting>
</example>
</section>