Great! Thanks all!


On 09/01/2015 05:32 PM, Brian West wrote:
https://wiki.freeswitch.org/wiki/Dialplan_XML#Nested_Condition_Caveats_and_Notes

This isn't moved over yet, or I can't find it on confluence.

On Tue, Sep 1, 2015 at 5:30 AM, Avi Marcus <avi@avimarcus.net> wrote:
Short answer: Each extension only has 1 set of conditions.
The condition evaluating foobar is run before it gets set.
After the play_and_get_digits you should transfer/execute_extension to a new extension that will evaluate ${foobar}

-Avi Marcus
BestFone

On Tue, Sep 1, 2015 at 11:56 AM, Dmitry Mordovin <d.mordovin@dwide.com> wrote:
Hello

<section name="dialplan" description="Local call">
     <context name="public">
       <extension name="local_1">

     <condition field="destination_number" expression="^(\d{4})$">
       <action application="answer"/>

       <action application="play_and_get_digits" data="1 1 3 7000 #
$${base_dir}/sounds/en/us/callie/conference/8000/conf-pin.wav
/invalid.wav foobar \d+"/>
       <action application="log" data="CRIT ${foobar}"/>

       <condition field="${foobar}" expression="1$">
             <action application="log" data="CRIT
--------------1------------------"/>
             <anti-action application="log" data="CRIT --------------not
1------------------"/>
       </condition>

       <action application="log" data="CRIT ---- last ${foobar}"/>
     </condition>

       </extension>
     </context>
   </section>

Why inner condition not works?

_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org



--

Brian West
brian@freeswitch.org


Twitter: @FreeSWITCH , @briankwest
http://www.freeswitchbook.com
http://www.freeswitchcookbook.com

Got Bugs? Report them here! | Reddit: /r/freeswitch

T:+19184209001 | F:+19184209002 | M:+1918424WEST (9378)
iNUM:+883 5100 1420 9001 | ISN:410*543 | Skype:briankwest



_________________________________________________________________________
Professional FreeSWITCH Consulting Services: 
consulting@freeswitch.org
http://www.freeswitchsolutions.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org