Hey,
On 30.03.2011 17:55, Alexandre Abreu wrote:
Using K 3.1.2. Before the setflag() that creates the dialog, I tried to use:
$dlg_ctx(flags) = 1;
Mar 30 12:29:03 devel kamailio: ERROR: dialog [dlg_var.c:165]: unknown PV name flags
I think the problem is that when using the flag to track dialogs, the module function that's actually responsible for starting the tracking (dlg_onreq()) kicks in only after the script has finished, which, unfortunately, is too late.
Does this suggestion make sense? Using another approach is it possible to execute this today?
Try calling dlg_manage() before you access dialog context data in the script. I can't tell if it works for context data but it does for dialog profiles.
If it still fails, an approach I'd suggest is to automatically trigger dialog creation when the user tries to access dialog data for the first time.
HTH,
--Timo