[Serusers] append_hf, append_urihf (append_furihf)
Daniel-Constantin Mierla
daniel at voice-system.ro
Thu Oct 6 11:09:41 CEST 2005
Hello Greg,
On 10/05/05 21:56, Greg Fausak wrote:
>Wow,
>
>I had to upgrade (I was on 0.8.12).
>Then I loaded avp and avpops and did the
>suggestion below.
>
> avp_write("$from","i:678");
> avp_pushto("$P-Asserted-ID","i:678");
>
>Worked great, the output looks like:
>
>P-Asserted-ID: sip:+12145551212 at test.com
>
>However, I need the output to look like:
>
>P-Asserted-ID: <sip:+12145551212 at test.com>
>
>Does avp let me format the output at all? I tried
>a bunch of stuff that didn't work.
>
>
only openser development version (cvs is frozen, it's going to be
released stable very soon, after testing thoroughly TLS and fixing a few
issues discovered while testing) has a function named avp_printf() which
can combine constant strings with avps or other pseudo-variables (see:
http://www.voice-system.ro/docs/avpops/ar01s06.html#avp_printf and
http://openser.org/docs/pseudo-variables.html).
Cheers,
Daniel
>This avp stuff is great. I should have looked at it
>a long time ago. Variables, what a concept ;-)
>
>-g
>
>
>
>
>
>
>
>On 10/5/05, Daniel-Constantin Mierla <daniel at voice-system.ro> wrote:
>
>
>>On 10/05/05 09:18, Juha Heinanen wrote:
>>
>>
>>
>>>Greg Fausak writes:
>>>
>>>
>>>
>>>>I was going to hack a append_urihf() into a append_furihf() to accomplish
>>>>the task...can I do this with an exec_dset or something else?
>>>>
>>>>
>>>a more general purpose solution would be to load from uri into an avp
>>>and then include that avp value into appended hf. perhaps there already
>>>exists a way to do so, i just have not needed it yet.
>>>
>>>
>>>
>>>
>>with avpops module:
>>
>>avp_write("$from","i:678");
>>avp_pushto("$P-Asserted-ID","i:678");
>>
>>Daniel
>>
>>
>>
>>>-- juha
>>>
>>>_______________________________________________
>>>Serusers mailing list
>>>serusers at lists.iptel.org
>>>http://lists.iptel.org/mailman/listinfo/serusers
>>>
>>>
>>>
>>>
>>>
>
>
>
>--
>Greg Fausak
>greg at thursday.com
>
>
>
More information about the sr-users
mailing list