At the moment, my Asterisk supports dial in several formats. (_XXXXX - Local city, _XXXXXXX - Moscow, _X. - Russia and international calls.)
This is very convenient for users, but complicates the contexts.
For example, the uplink contexts has templates for all formats.
I want to write a handler that make normalization of the dialed number to the format ITU-T E.164. And next process the numbers in the one format.
To my surprise, the variable ${EXTEN} does not store rewritten value.
I think that I went the wrong way.
How correctly implement the normalizer of dialed number?