A yes, sorry.<br>I don't use lua with FS that much either.<br>But i got it from here:<br><a href="http://wiki.freeswitch.org/wiki/Session_getVariable">http://wiki.freeswitch.org/wiki/Session_getVariable</a><br><br><pre>
var caller_id =session.getVariable("caller_id_number")</pre>I can see that page is the one that is wrong (will correct it now).<br><br><br><div class="gmail_quote">On Tue, Jul 3, 2012 at 7:38 PM, Peter Olsson <span dir="ltr"><<a href="mailto:peter.olsson@visionutveckling.se" target="_blank">peter.olsson@visionutveckling.se</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div link="blue" vlink="purple" lang="SV">
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1f497d" lang="EN-US">Hmm... I’ve never used Lua, but that means that all documentation for mod_lua on the wiki is wrong? Sounds strange to me...<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1f497d" lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1f497d" lang="EN-US">/Peter<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"" lang="EN-US">Från:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"" lang="EN-US"> <a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a> [mailto:<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a>]
<b>För </b>mayamatakeshi<br>
<b>Skickat:</b> den 3 juli 2012 12:25</span></p><div class="im"><br>
<b>Till:</b> FreeSWITCH Users Help<br>
<b>Ämne:</b> Re: [Freeswitch-users] how to get the content of sip header ?<u></u><u></u></div><p></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<div><div class="im">
<p class="MsoNormal">On Tue, Jul 3, 2012 at 7:16 PM, Samira Mh <<a href="mailto:saami_mh@ymail.com" target="_blank">saami_mh@ymail.com</a>> wrote:<u></u><u></u></p>
<div>
<div>
<div>
<div>
<p class="MsoNormal">for example i want to read the value of sip-header ' CSeq' in lua(that is configure for mod_xml in /usr/loca/freeswitch/conf/autoload/lia.xml.conf), must to issue as follow:<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">local var = session:getVariable("sip_CSeq")<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">but the error occure:<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> attempt to index global 'session' (a nil value)<u></u><u></u></p>
</div>
</div>
</div>
</div>
</div><div>
<p class="MsoNormal"><br>
Lua syntax error. It should be:<u></u><u></u></p>
</div>
</div>
<p class="MsoNormal">local var = session.getVariable("sip_CSeq")<br>
<br>
regards,<br>
Takeshi.<br>
!DSPAM:4ff2c7f532762054221329! <u></u><u></u></p>
</div>
</div>
<br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
Join Us At ClueCon - Aug 7-9, 2012<br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>