So i am adding a call transfer facility in my code .When user dials the number of executive and executive picks the then executive has the authority to transfer the call to specific extension
[from-pstn]
exten=>_X.,1,Playback(hello-world)
exten=>_X.,n,set(__GOTO_ON_BLINDXFR=from-pstn^123456^1)
exten=>_X.,n,Goto(mycontext)
[mycontext]
exten=>_X.,1,dial(DAHDI/g0/0${9xxxxxxxxx},,mtG(recordvoice,${EXTEN},1))
[recordvoice]
exten=>_X.,1,Mixmonitor(myvoice.wav)
description of t option in dial
t: Allow the called user to transfer the call by hitting the blind xfer keys (features.conf) Does not affect transfers initiated through other methods.
If you have set the variable GOTO_ON_BLINDXFR then the transferrer will be sent to the context|exten|pri (you can use ^ to represent | to avoid escapes), example: SetVar(GOTO_ON_BLINDXFR=woohoo^s^1); works with both t and T
but when call connects and executive press '#'(default call transfer key) then call is not transfer and cli shows
Unable to find extension '' in context 'mycontext'
By default asterisk search for the extension in the same context and it receives an empty extention. You can specify extension by pressing the extention after pressing # and in your dialplan you can route it to different context.For ex
and when the call is connected press 123 after # to transfer the call.
Cheers