[Freeswitch-users] LUA getVariable

Chad Phillips chad at apartmentlines.com
Fri Jan 6 21:04:11 MSK 2012


this might do the trick:  

http://wiki.freeswitch.org/wiki/Variable_session_in_hangup_hook  


Sent with Sparrow (http://www.sparrowmailapp.com/?sig)


On Friday, January 6, 2012 at 4:46 AM, Juan Antonio Ibañez Santorum wrote:

> Hello,
>  
>    I have one LUA script that make calls to one custom FS app. That app sets up some session channel variables and makes an outgoing call:
>  
> > if(caller_channel = switch_core_session_get_channel(session)){
> >    switch_channel_set_variable(caller_channel, "var", "val")
> >  
> > }
> >  
> >  
>  
>  
>    If the caller hangs up the call, the app returns and I try to get the val of var as:
>  
> > session:getVariable("var")  
>  
>    but a nil value is returned. Do you know why?
>  
> Regards
>  
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org (mailto:consulting at freeswitch.org)
> http://www.freeswitchsolutions.com
>  
> 
> 
>  
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
>  
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org (mailto:FreeSWITCH-users at lists.freeswitch.org)
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>  
>  


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120106/a7178252/attachment.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list