<br><br><div class="gmail_quote">On Mon, Nov 15, 2010 at 3:19 PM, Anthony Cosgrove <span dir="ltr">&lt;<a href="mailto:acosgrov@gmail.com">acosgrov@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div style="word-wrap: break-word;"><div>I would think in this situation you would need to either use a dynamic dialplan to return the 302 to whatever destination you wish (<a href="http://wiki.freeswitch.org/wiki/Mod_xml_curl" target="_blank">http://wiki.freeswitch.org/wiki/Mod_xml_curl</a>), or if staying static a continue_on_fail branch along with lua to fetch your destination value.</div>
<div><br></div><div>After a quick look at google looks like my line of thinking is somewhat on track... </div><div><br></div><div><span style="font-family: arial,sans-serif; line-height: 19px;"><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank">Old Nabble - </a><i style="font-weight: bold; font-style: normal;"><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank">Freeswitch</a></i><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank">-users - 302 redirects and </a><i style="font-weight: bold; font-style: normal;"><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank">continue_on_fail</a></i><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank"> </a><b><a href="http://old.nabble.com/302-redirects-and-continue_on_fail%3Dtrue-td24544501.html" style="color: rgb(34, 0, 193);" target="_blank">...</a></b></span></div>
<div><span style="font-family: arial,sans-serif; line-height: 19px;"><span style="line-height: 15px;"><a href="http://www.google.com/url?q=http://lists.freeswitch.org/pipermail/freeswitch-users/2009-July/016903.html&amp;sa=X&amp;ei=zD7hTMTkM4WglAe-5_TMAw&amp;ved=0CDIQrAIoAzAD&amp;usg=AFQjCNGc7F3s8UprN9V3M6iaV7L-NBsnog" style="color: rgb(34, 0, 193);" target="_blank">302 redirects and <i style="font-weight: bold; font-style: normal;">continue_on_fail</i>=true</a>‎ - <span style="color: rgb(118, 118, 118);">Jul 18, 2009</span></span></span></div>
<div><span style="font-family: arial,sans-serif; line-height: 19px;"><span style="line-height: 15px;"><span style="color: rgb(118, 118, 118);"><span style="color: rgb(34, 0, 193); line-height: 19px;">[<i style="font-weight: bold; font-style: normal;">Freeswitch</i>-users] &quot;<i style="font-weight: bold; font-style: normal;">continue on fail</i>&quot; howto</span></span></span></span></div>
<br></div></blockquote></div><br><br>thanks for your answer ....<br><br>actually im looking at something like this... still need to test it and see what the scalability might be.<br><br><br><br><br>put this in context features:<br>
<br><br>  &lt;extension name=&quot;A-CFU&quot;&gt;<br>    &lt;condition field=&quot;destination_number&quot; expression=&quot;^\*21\*(\d.*)$&quot;&gt;<br><br>      &lt;action application=&quot;db&quot; data=&quot;insert/FWD-${caller_id_number}/U/$1&quot;/&gt;<br>
      <br>      &lt;!-- play appropriate confirmation tone --&gt;<br>      &lt;action application=&quot;hangup&quot;/&gt;<br>    &lt;/condition&gt;<br>  &lt;/extension&gt;<br><br><br><br>  &lt;extension name=&quot;D-CFU&quot;&gt;<br>
    &lt;condition field=&quot;destination_number&quot; expression=&quot;^\#21\#$&quot;&gt;<br><br>      &lt;action application=&quot;db&quot; data=&quot;delete/FWD-${caller_id_number}/U&quot;/&gt;<br><br>      &lt;!-- play appropriate confirmation tone --&gt;<br>
      &lt;action application=&quot;hangup&quot;/&gt;<br>    &lt;/condition&gt;<br>  &lt;/extension&gt;<br><br><br>  &lt;extension name=&quot;check_if_forwarded&quot;&gt;<br><br>    &lt;condition field=&quot;destination_number&quot; expression=&quot;^check_if_forwarded$&quot;/&gt;<br>
    &lt;condition field=&quot;${forwarded-to}&quot; expression=&quot;^$&quot;/&gt;<br>        &lt;action application=&quot;export&quot; data=&quot;to_dial=user/${dialed_extension}&quot;/&gt;<br>    &lt;/condition&gt;<br><br>
    &lt;condition field=&quot;destination_number&quot; expression=&quot;^check_if_forwarded$&quot;/&gt;<br>    &lt;condition field=&quot;${forwarded-to}&quot; expression=&quot;^(10[01][0-9])$&quot;/&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;sip_h_Diversion=&lt;sip:${dialed_extension}@${sip_from_host};user=phone&gt;;reason=unconditional&quot;/&gt;        <br>
        &lt;action application=&quot;export&quot; data=&quot;to_dial=user/${forwarded-to}&quot;/&gt;<br>    &lt;/condition&gt;<br><br>    &lt;condition field=&quot;destination_number&quot; expression=&quot;^check_if_forwarded$&quot;/&gt;<br>
    &lt;condition field=&quot;${forwarded-to}&quot; expression=&quot;^(0.*)$&quot;/&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;sip_h_Diversion=&lt;sip:${dialed_extension}@${sip_from_host};user=phone&gt;;reason=unconditional&quot;/&gt;<br>
        &lt;action application=&quot;export&quot; data=&quot;to_dial=loopback/${forwarded-to}&quot;/&gt;<br>    &lt;/condition&gt;<br>  &lt;/extension&gt;<br><br><br><br>In context default just execute this to populate forwarded-to variable:<br>
<br>  &lt;extension name=&quot;isForwarded&quot;&gt;<br>    &lt;condition&gt;<br>      &lt;action application=&quot;set&quot; data=&quot;forwarded-to=${db(select/FWD-${destination_number}/U)}&quot;/&gt;<br>    &lt;/condition&gt;<br>
  &lt;/extension&gt;<br><br><br><br><br><br>modify just a bit the LocalExtension :)<br><br><br>    &lt;extension name=&quot;Local_Extension&quot;&gt;<br>      &lt;condition field=&quot;destination_number&quot; expression=&quot;^(10[01][0-9])$&quot;&gt;<br>
        &lt;action application=&quot;set&quot; data=&quot;dialed_extension=$1&quot;/&gt;<br>        &lt;action application=&quot;export&quot; data=&quot;dialed_extension=$1&quot;/&gt;<br>        &lt;!-- bind_meta_app can have these args &lt;key&gt; [a|b|ab] [a|b|o|s] &lt;app&gt; --&gt;<br>
        &lt;action application=&quot;bind_meta_app&quot; data=&quot;1 b s execute_extension::dx XML features&quot;/&gt;<br>        &lt;action application=&quot;bind_meta_app&quot; data=&quot;2 b s record_session::$${recordings_dir}/${caller_id_number}.${strftime(%Y-%m-%d-%H-%M-%S)}.wav&quot;/&gt;<br>
        &lt;action application=&quot;bind_meta_app&quot; data=&quot;3 b s execute_extension::cf XML features&quot;/&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;ringback=${us-ring}&quot;/&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;transfer_ringback=$${hold_music}&quot;/&gt;<br>
        &lt;action application=&quot;set&quot; data=&quot;call_timeout=30&quot;/&gt;<br>        &lt;!-- &lt;action application=&quot;set&quot; data=&quot;sip_exclude_contact=${network_addr}&quot;/&gt; --&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;<br>
        &lt;!--&lt;action application=&quot;set&quot; data=&quot;continue_on_fail=NORMAL_TEMPORARY_FAILURE,USER_BUSY,NO_ANSWER,TIMEOUT,NO_ROUTE_DESTINATION&quot;/&gt; --&gt;<br>        &lt;action application=&quot;set&quot; data=&quot;continue_on_fail=true&quot;/&gt;<br>
        &lt;action application=&quot;hash&quot; data=&quot;insert/${domain_name}-call_return/${dialed_extension}/${caller_id_number}&quot;/&gt;<br>        &lt;action application=&quot;hash&quot; data=&quot;insert/${domain_name}-last_dial_ext/${dialed_extension}/${uuid}&quot;/&gt;<br>
        &lt;action application=&quot;set&quot; data=&quot;called_party_callgroup=${user_data(${dialed_extension}@${domain_name} var callgroup)}&quot;/&gt;<br>        &lt;!--&lt;action application=&quot;export&quot; data=&quot;nolocal:sip_secure_media=${user_data(${dialed_extension}@${domain_name} var sip_secure_media)}&quot;/&gt;--&gt;<br>
        &lt;action application=&quot;hash&quot; data=&quot;insert/${domain_name}-last_dial/${called_party_callgroup}/${uuid}&quot;/&gt;<br><br><br>        &lt;!-- check if the destination is actually forwarded --&gt;<br>        &lt;action application=&quot;execute_extension&quot; data=&quot;check_if_forwarded&quot; XML features/&gt;<br>
<br><br>        &lt;action application=&quot;bridge&quot; data=&quot;${to_dial}@${domain_name}&quot;/&gt;<br><br><br>        &lt;action application=&quot;answer&quot;/&gt;<br>        &lt;action application=&quot;sleep&quot; data=&quot;1000&quot;/&gt;<br>
        &lt;action application=&quot;bridge&quot; data=&quot;loopback/app=voicemail:default ${domain_name} ${dialed_extension}&quot;/&gt;<br>      &lt;/condition&gt;<br>    &lt;/extension&gt;<br><br><br><br><br><br><br><br>
<br><br><br><br>