> On 05 Nov 2015, at 10:15, Daniel Tryba <d.tr...@pocos.nl> wrote:
> 
>> Based on the xlog output, the following doesn't appear to be working -
>> remove_hf("Contact");
>> append_hf("Contact: $var(newct)\r\n");
>> 
>> I've actually had a similar issue before replacing a hdr so I'm wondering if
>> I'm doing something wrong?
> 
> Header manipulation is doesn't update the already parsed message that is 
> being 
> used for $hdr etc.
This is an important fact for all routing scripts. You have one message in 
memory that you
read from and one copy that you apply changes on. The changes are applied when 
you send
the message or when you run the function below.

> You have to apply the changes with
> http://kamailio.org/docs/modules/stable/modules/textopsx.html#textopsx.f.msg_apply_changes

Not that if you run this function you owerwrite the incoming message and have 
no way of going
back to the original incoming message. 

/O
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

Reply via email to