<div dir="ltr"><div>Hi Jim,<br><br></div>get the variables from the session:<br><br><a href="https://freeswitch.org/confluence/display/FREESWITCH/Lua+API+Reference#LuaAPIReference-session:getVariable">https://freeswitch.org/confluence/display/FREESWITCH/Lua+API+Reference#LuaAPIReference-session:getVariable</a><br><br><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 30, 2015 at 10:21 PM, Jim Lynch <span dir="ltr">&lt;<a href="mailto:jim@k4gvo.com" target="_blank">jim@k4gvo.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I have a line in my dialplan that looks like this:<br>
     &lt;action application=&quot;lua&quot; data=&quot;cid.lua  ${caller_id_name}<br>
${caller_id_number}&quot; /&gt;<br>
<br>
However when the program is executed and the caller_id_name has a space<br>
in it, the number gets lost.<br>
I can&#39;t figure out a way to add delimiters that get passed to the<br>
shell.  None of these work:<br>
<br>
     &lt;action application=&quot;lua&quot; data=&quot;cid.lua \&quot;${caller_id_name}\&quot;<br>
\&quot;${caller_id_number}\&quot;&quot; /&gt;<br>
or<br>
     &lt;action application=&quot;lua&quot; data=&quot;cid.lua &#39;&#39;${caller_id_name}&#39;&#39;<br>
&#39;&#39;${caller_id_number}&#39;&#39;&quot; /&gt;<br>
or<br>
     &lt;action application=&quot;lua&quot; data=&quot;cid.lua \&quot;\&quot;${caller_id_name}\&quot;\&quot;<br>
\&quot;\&quot;${caller_id_number}\&quot;\&quot;&quot; /&gt;<br>
<br>
None of those work.  The quotes are all stripped off when running this test<br>
<br>
lua file:<br>
tmp_file = &quot;/tmp/cidtest.txt&quot;;<br>
local file = assert(io.open(tmp_file, &quot;a&quot;));<br>
local m_name=argv[1];<br>
local m_number=argv[2];<br>
file:write(&quot;j cid is &quot;,m_name,&quot; number is &quot;,m_number,&quot;\n&quot;);<br>
<br>
Any suggestions?<br>
<br>
Thanks,<br>
Jim.<br>
<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>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><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>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">Sincerely,<br><br>Giovanni Maruzzelli<br>Cell : +39-347-2665618<br></div>
</div>