John Kiniston <johnkiniston at gmail.com> schrieb:> The easiest solution may be to strip the leading zero's off your caller ID > before your caller enters the Voicemail app to leave you a message. > > > ExecIf(REGEX("^[0][0]." > ${CALLERID(NUM)})?Set(CALLERID(num)=${CALLERID(NUM):2}))Thanks! I already had this idea and implemented it. It works... Regards Luca Bertoncello (lucabert at lucabert.de)
On Monday 06 Jul 2015, Luca Bertoncello wrote:> John Kiniston <johnkiniston at gmail.com> schrieb: > > The easiest solution may be to strip the leading zero's off your caller > > ID before your caller enters the Voicemail app to leave you a message. > > > > > > ExecIf(REGEX("^[0][0]." > > ${CALLERID(NUM)})?Set(CALLERID(num)=${CALLERID(NUM):2})) > > Thanks! > > I already had this idea and implemented it. > It works...Even better, if the first 4 digits are "0049", you could replace them with "0" as though it was an inland call: ExecIf(REGEX("^0049." ${CALLERID(NUM)})?Set(CALLERID(num)=0${CALLERID(NUM):4})) -- AJS Note: Originating address only accepts e-mail from list! If replying off- list, change address to asterisk1list at earthshod dot co dot uk .
Nice! I didn't know what dialing rules may apply to his location, Your code does look like an improvement on mine tho. I love the REGEX function. Even better, if the first 4 digits are "0049", you could replace them with> "0" > as though it was an inland call: > > ExecIf(REGEX("^0049." > ${CALLERID(NUM)})?Set(CALLERID(num)=0${CALLERID(NUM):4})) > > --A human being should be able to change a diaper, plan an invasion, butcher a hog, conn a ship, design a building, write a sonnet, balance accounts, build a wall, set a bone, comfort the dying, take orders, give orders, cooperate, act alone, solve equations, analyze a new problem, pitch manure, program a computer, cook a tasty meal, fight efficiently, die gallantly. Specialization is for insects. ---Heinlein -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150707/819641dd/attachment.html>