Hi,
Sometimes the user dials with country code (62 or +62) and they might also dial 0, for example: 628112345678 or +628112345678 or 08112345678, question:
How to strip the digits and add 0 as the prefix if they dials with 62 or +62 and add 1 digit 0, so in my case above: if they dial 628112345678 or +628112345678 --> then it would changed to 08112345678.
mine was:
<extension name="cs-622131111111" continue="false" uuid="4420efd3-702e-4aee-bd04-5ae872bf6a18">
<condition field="${user_exists}" expression="false"/>
<condition field="destination_number" expression="^(\d+)$">
<action application="export" data="call_direction=outbound" inline="true"/>
<action application="unset" data="call_timeout"/>
<action application="set" data="hangup_after_bridge=true"/>
<action application="set" data="effective_caller_id_name=${outbound_caller_id_name}"/>
<action application="set" data="effective_caller_id_number=${outbound_caller_id_number}"/>
<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=1,2,3,6,18,21,27,28,31,34,38,41,42,44,58,88,111,403,501,602,607,809"/>
<action application="bridge" data="sofia/gateway/f6459421-00c3-492a-ad7d-65d6a161ba1d/$1"/>
</condition>
</extension>
anybody can give me suggestion?
Sometimes the user dials with country code (62 or +62) and they might also dial 0, for example: 628112345678 or +628112345678 or 08112345678, question:
How to strip the digits and add 0 as the prefix if they dials with 62 or +62 and add 1 digit 0, so in my case above: if they dial 628112345678 or +628112345678 --> then it would changed to 08112345678.
mine was:
<extension name="cs-622131111111" continue="false" uuid="4420efd3-702e-4aee-bd04-5ae872bf6a18">
<condition field="${user_exists}" expression="false"/>
<condition field="destination_number" expression="^(\d+)$">
<action application="export" data="call_direction=outbound" inline="true"/>
<action application="unset" data="call_timeout"/>
<action application="set" data="hangup_after_bridge=true"/>
<action application="set" data="effective_caller_id_name=${outbound_caller_id_name}"/>
<action application="set" data="effective_caller_id_number=${outbound_caller_id_number}"/>
<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=1,2,3,6,18,21,27,28,31,34,38,41,42,44,58,88,111,403,501,602,607,809"/>
<action application="bridge" data="sofia/gateway/f6459421-00c3-492a-ad7d-65d6a161ba1d/$1"/>
</condition>
</extension>
anybody can give me suggestion?