Hello Andrew, some preliminary tests show that it works. I have to rebuild the docker image to get the mod to be built however, so I can't do this in production right away but it looks like I can consolidate a few rules with that. thanks for your help Joern Von: "Andrew Cassidy" <andrew@cassidywebservices.co.uk> An: "FreeSWITCH Users Help" <freeswitch-users@lists.freeswitch.org> Gesendet: Freitag, 11. September 2015 10:37:04 Betreff: Re: [Freeswitch-users] Replacing leading "+" in outgoing numbers I use mod_translate for that sort of thing but that's personal preference. On 11 September 2015 at 09:28, Jörn Ott < joern.ott@ext.chefkoch.de > wrote: Hello guys, its not the digits causing problems but the \+ at the beginning. My routes for national calls ^0(\d\d\d\d\d*)$ and international calls ^00(\d\d\d\d\d*)$ work fine that way (targetting all numbers which are longer than internal numbers and have a leading 0 or 00). The problem happens, if add a similar rule starting with a literal + (\+), then I am getting switch parse errors. Kind regards Joern Von: "Ken Rice" < krice@freeswitch.org > An: "FreeSWITCH Users Help" < freeswitch-users@lists.freeswitch.org > Gesendet: Freitag, 11. September 2015 04:13:59 Betreff: Re: [Freeswitch-users] Replacing leading "+" in outgoing numbers \d* is wrong… should be \d+ or maybe \d.* From: freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org ] On Behalf Of Jörn Ott Sent: Thursday, September 10, 2015 7:16 AM To: FreeSWITCH Users Help < freeswitch-users@lists.freeswitch.org > Subject: [Freeswitch-users] Replacing leading "+" in outgoing numbers Hello all, I am using FusionPBX and freeswitch. Incoming calls are signalled with a leading + and also stored in the snom phones call lists. If someone tries to call back an external caller, I tried to strip off the leading + on the outgoing call with the following condition: <extension name="ext.ddddd" > <condition field="destination_number" expression="^\+(\d\d\d\d\d*)$" > <action application="set" data="sip_h_X-accountcode=${accountcode}" /> <action application="set" data="sip_h_X-Tag=" /> <action application="set" data="call_direction=outbound" /> <action application="set" data="hangup_after_bridge=true" /> <action application="set" data="inherit_codec=true" /> <action application="set" data="ignore_display_updates=true" /> <action application="set" data="callee_id_number=$1" /> <action application="set" data="continue_on_fail=true" /> <action application="set" data="outbound_prefix=+" /> <action application="bridge" data="sofia/gateway/781c8f7f-5d96-4e9e-8939-423b883cb675/$1" /> </condition> </extension> Sadly, the condition field already generates compile error. Can you give me a hint, how I can strip the + from the dialled number? Kind regards Joern -- -- Jörn Ott Systemadministrator Chefkoch GmbH Joseph-Schumpeter-Allee 33 53227 Bonn Telefon +49 228 28669-50 Telefax +49 228 28669-511 joern.ott@ext.chefkoch.de | http://www.chefkoch.de HRB 18761, Amtsgericht Bonn Geschäftsführer: Martin Meister, Sven Giebler, Arne Wolter Ein Unternehmen von Gruner+Jahr. _________________________________________________________________________ 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 -- Andrew Cassidy BSc (Hons) MBCS SSCA Managing Director T 03300 100 960 F 03300 100 961 E andrew@cassidywebservices.co.uk W www.cassidywebservices.co.uk _________________________________________________________________________ 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