<html><body><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div>Hello guys,<br></div><div><br data-mce-bogus="1"></div><div>its not the digits causing problems but the \+ at the beginning.<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>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&nbsp; add a similar rule starting with a literal + (\+), then I am getting switch parse errors.<br><div></div></div><div><br></div><div>Kind regards<br data-mce-bogus="1"></div><div>Joern<br data-mce-bogus="1"></div><div><br></div><hr id="zwchr" data-marker="__DIVIDER__"><div data-marker="__HEADERS__"><b>Von: </b>"Ken Rice" &lt;krice@freeswitch.org&gt;<br><b>An: </b>"FreeSWITCH Users Help" &lt;freeswitch-users@lists.freeswitch.org&gt;<br><b>Gesendet: </b>Freitag, 11. September 2015 04:13:59<br><b>Betreff: </b>Re: [Freeswitch-users] Replacing leading "+" in outgoing numbers<br></div><div><br></div><div data-marker="__QUOTED_TEXT__"><style><!--

@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}

p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><div class="WordSection1"><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,sans-serif;color:#1F497D">\d* is wrong… should be \d+ or maybe \d.*</span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,sans-serif;color:#1F497D">&nbsp;</span></p><div><div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in"><p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,sans-serif">From:</span></b><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,sans-serif"> freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] <b>On Behalf Of </b>Jörn Ott<br><b>Sent:</b> Thursday, September 10, 2015 7:16 AM<br><b>To:</b> FreeSWITCH Users Help &lt;freeswitch-users@lists.freeswitch.org&gt;<br><b>Subject:</b> [Freeswitch-users] Replacing leading "+" in outgoing numbers</span></p></div></div><p class="MsoNormal">&nbsp;</p><div><div><div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">Hello all,</span></p></div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&nbsp;</span></p><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">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:</span></p></div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&lt;extension name="ext.ddddd" &gt;<br>&nbsp;&nbsp; &lt;condition field="destination_number" expression="^\+(\d\d\d\d\d*)$" &gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="sip_h_X-accountcode=${accountcode}" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="sip_h_X-Tag=" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="call_direction=outbound" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="hangup_after_bridge=true" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="inherit_codec=true" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="ignore_display_updates=true" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="callee_id_number=$1" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="continue_on_fail=true" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="set" data="outbound_prefix=+" /&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application="bridge" data="sofia/gateway/781c8f7f-5d96-4e9e-8939-423b883cb675/$1" /&gt;<br>&nbsp;&nbsp; &lt;/condition&gt;<br>&lt;/extension&gt;</span></p></div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&nbsp;</span></p><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">Sadly, the condition field already generates compile error.</span></p></div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&nbsp;</span></p><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">Can you give me a hint, how I can strip the + from the dialled number?</span></p></div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&nbsp;</span></p><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">Kind regards</span></p></div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">Joern</span></p></div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">-- </span></p></div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">--<br>Jörn Ott<br>Systemadministrator<br><br>Chefkoch GmbH<br>Joseph-Schumpeter-Allee 33<br>53227 Bonn<br><br>Telefon +49 228 28669-50<br>Telefax +49 228 28669-511<br><a href="mailto:joern.ott@ext.chefkoch.de" target="_blank">joern.ott@ext.chefkoch.de</a> | <a href="http://www.chefkoch.de" target="_blank">http://www.chefkoch.de</a><br><br>HRB 18761, Amtsgericht Bonn<br>Geschäftsführer: Martin Meister, Sven Giebler, Arne Wolter<br>Ein Unternehmen von Gruner+Jahr.</span></p></div></div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,sans-serif;color:black">&nbsp;</span></p></div></div></div><br>_________________________________________________________________________<br>Professional FreeSWITCH Consulting Services: <br>consulting@freeswitch.org<br>http://www.freeswitchsolutions.com<br><br>Official FreeSWITCH Sites<br>http://www.freeswitch.org<br>http://confluence.freeswitch.org<br>http://www.cluecon.com<br><br>FreeSWITCH-users mailing list<br>FreeSWITCH-users@lists.freeswitch.org<br>http://lists.freeswitch.org/mailman/listinfo/freeswitch-users<br>UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users<br>http://www.freeswitch.org<br></div></div></body></html>