TUTORIAL Call forwarding by dialing in

tomsyr

Guru
Joined
Oct 26, 2007
Messages
266
Reaction score
1
Is it possible to turn on call forwarding remotely? For example, if I were to dial in to listen to my voicemail, is there a way to turn on call forwarding for my extension?
Thanks,
Tom
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,205
Reaction score
5,225
Sure. Dial into DISA and *72. To deactivate, *74.
 

tomsyr

Guru
Joined
Oct 26, 2007
Messages
266
Reaction score
1
Call forwarding

I'm thinking more from the perspective of users with extensions being able to forward calls based on their extension numbers...
Possibly a IVR where they could enter into a routine where they would be prompted for their extension, then their voice mail pass-code, then the phone number that they want calls forwarded to.
Does something like this already exist?
Thanks,
Tom
 
Joined
Apr 17, 2009
Messages
829
Reaction score
9
that would be a great idea. I would love to do something like this as well.
 

tomsyr

Guru
Joined
Oct 26, 2007
Messages
266
Reaction score
1
Bounty for call forwarding

If this functionality does not exist, would someone be interested in building it? Please PM me. If I have this built, I'll contribute it back to the community.
Thanks,
Tom
 
Joined
Apr 17, 2009
Messages
829
Reaction score
9
i may be down to help a little bit. it would be of great benefit to everyone. it would be nice if it would almost prompt and ask if th number you called in on was what you wanted forwarded or if you wanted to enter a different number...
 

tomsyr

Guru
Joined
Oct 26, 2007
Messages
266
Reaction score
1
Solution for remotely enabling call forwarding via the phone

RonW was able to help me use existing FreePBX code to enable call forwarding remotely by phone.
As I had been searching for a solution, others were looking for the same functionality – an example I saw was:
“A sales guy is stuck in traffic, and is expecting an important call from a client. The sales guy dials into the system, and turns on call forwarding…”
To me – having this functionality is allot like everything else about Asterisk/FreePBX – you don’t need something until a new scenario comes along. Once again, it seems like anything some other phone system does, Asterisk can do as well.

The first part is to put the following code into the extensions_custom.conf:
[from-racf]
exten => 72,1,Answer
exten => 72,n,Wait(1)
exten => 72,n,Macro(user-callerid,)
exten => 72,n,Playback(call-fwd-unconditional)
exten => 72,n,Playback(please-enter-your&extension)
exten => 72,n,Read(fromext,then-press-pound,,,,)
exten => 72,n,Set(fromext=${IF($["foo${fromext}"="foo"]?${AMPUSER}:${fromext})})
exten => 72,n,Wait(1)
exten => 72,n(startread),Playback(ent-target-attendant)
exten => 72,n,Read(toext,then-press-pound,,,,)
exten => 72,n,GotoIf($["foo${toext}"="foo"]?startread)
exten => 72,n,Wait(1)
exten => 72,n,Set(DB(CF/${fromext})=${toext})
exten => 72,n,Playback(call-fwd-unconditional&for&extension)
exten => 72,n,SayDigits(${fromext})
exten => 72,n,Playback(is-set-to)
exten => 72,n,SayDigits(${toext})
exten => 72,n,Macro(hangupcall,)
exten => _72.,1,Answer
exten => _72.,n,Wait(1)
exten => _72.,n,Macro(user-callerid,)
exten => _72.,n,Set(DB(CF/${AMPUSER})=${EXTEN:2})
exten => _72.,n,Playback(call-fwd-unconditional&for&extension)
exten => _72.,n,SayDigits(${AMPUSER})
exten => _72.,n,Playback(is-set-to)
exten => _72.,n,SayDigits(${EXTEN:2})
exten => _72.,n,Macro(hangupcall,)
exten => 73,1,Answer
exten => 73,n,Wait(1)
exten => 73,n,Macro(user-callerid,)
exten => 73,n,dbDel(CF/${AMPUSER})
exten => 73,n,Playback(call-fwd-unconditional&de-activated)
exten => 73,n,Macro(hangupcall,)
exten => _73.,1,Answer
exten => _73.,n,Wait(1)
exten => _73.,n,Set(fromext=${EXTEN:2})
exten => _73.,n,dbDel(CF/${fromext})
exten => _73.,n,Playback(call-fwd-unconditional&for&extension)
exten => _73.,n,SayDigits(${fromext})
exten => _73.,n,Playback(cancelled)
exten => _73.,n,Macro(hangupcall,)
exten => 74,1,Answer
exten => 74,n,Wait(1)
exten => 74,n,Playback(please-enter-your&extension)
exten => 74,n,Read(fromext,then-press-pound,,,,)
exten => 74,n,Wait(1)
exten => 74,n,dbDel(CF/${fromext})
exten => 74,n,Playback(call-fwd-unconditional&for&extension)
exten => 74,n,SayDigits(${fromext})
exten => 74,n,Playback(cancelled)
exten => 74,n,Macro(hangupcall,)
exten => h,1,Hangup
exten => i,1,Hangup
exten => T,1,Hangup

Then put the following in the vm_general .inc
dialout=from-racf

To use the code, the user would call into their voice mail, and then go into advanced options (3), then press 4 which enables the racf code. From there, the user would enter in the following:
72NXXXXX# or 72NXXNXXXXXX# (Sub the N & X for their phone number they want to forward to). If they just want to forward to another extension, they would put in 72XXX#

To turn off call forwarding, they would follow the same procedure - but then dial 73# after they press 4 within advanced options.

Ron also pointed out that instead of putting the dialout=racf in the vm_general.inc, you can limit who gets this functionality by putting dialout=racf in the extension within FreePBX. Scroll down to the Voicemail & Directory section, and in the ‘VM Options’ text field, enter in dialout=racf

I still have some more work to do before implementing – like changing the voice prompts to be more specific for the actual usage, etc – but this does exactly what I want it do as far as functionality.

Thanks again RonW!
Tom
 
Joined
Apr 17, 2009
Messages
829
Reaction score
9
this is great.

i will soon try this out. I am looking forward to it as it is a great option.
 

bjeung

Member
Joined
Dec 30, 2008
Messages
116
Reaction score
0
Any get this to work? I can call in, and press 3 and the 4. I put in my call forward number and it reads it back to me and then hangs up. Doesn't seem to actually set the call forwarding or store the number anywhere.
 

tbrummell

Guru
Joined
Jan 8, 2011
Messages
1,275
Reaction score
339
You will notice the original post is from 2009, code may need to be changed to work on newer flavors.
 
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top