transfer is a final action, the script must exit once it&#39;s been transferred.<div>i think you need to explain what you really want to do.</div><div>if it&#39;s just play a file use session:execute(&quot;playback&quot;, &quot;file.wav&quot;)</div>
<div><br></div><div><br><div class="gmail_quote">On Mon, Jul 5, 2010 at 2:06 PM, Tony Tin <span dir="ltr">&lt;<a href="mailto:tony.tin@noahmedia.com.hk">tony.tin@noahmedia.com.hk</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi,<br><br>I&#39;m trying to bridge 2 openzap channels, one is inbound call, another is outbound call. <br><br>Below is the Lua script which originates the outbound call in the inbound call dialplan.<br><br>If the &quot;transfer&quot; line is commented out, bridge is working fine. I suspect it is about call legs, but I can find the proper way to set then up. Could anyone please help, thanks.<br>

 <br>-------------------------------------------------------------------------------------<br><br>session_orig = freeswitch.Session(&quot;OpenZAP/2/a/98877666&quot;)<br><br>while session:getState()~=&quot;CS_HANGUP&quot; do<br>

    os.execute(&quot;usleep 500000&quot;)<br>    if session_orig:answered() then<br>        break<br>    end<br>end<br><br>-- need to play message to called party before bridge<br>-- comment out the below line, then bridge is working<br>

session_orig:transfer(&quot;orig_ext&quot;, &quot;xml&quot;, &quot;default&quot;)<br><br>freeswitch.bridge(session, session_orig)<br><br>-------------------------------------------------------------------------------------<br>

<br>Regards,<br><font color="#888888">Tony<br><br>
</font><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><br clear="all"><br>-- <br>Anthony Minessale II<br><br>FreeSWITCH <a href="http://www.freeswitch.org/">http://www.freeswitch.org/</a><br>ClueCon <a href="http://www.cluecon.com/">http://www.cluecon.com/</a><br>
Twitter: <a href="http://twitter.com/FreeSWITCH_wire">http://twitter.com/FreeSWITCH_wire</a><br><br>AIM: anthm<br><a href="mailto:MSN%3Aanthony_minessale@hotmail.com">MSN:anthony_minessale@hotmail.com</a><br>GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com">PAYPAL:anthony.minessale@gmail.com</a><br>
IRC: <a href="http://irc.freenode.net">irc.freenode.net</a> #freeswitch<br><br>FreeSWITCH Developer Conference<br><a href="mailto:sip%3A888@conference.freeswitch.org">sip:888@conference.freeswitch.org</a><br><a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org">googletalk:conf+888@conference.freeswitch.org</a><br>
pstn:+19193869900<br>
</div>