So what am I trying to do?
Well I've just moved from asterisk to SER and now i'm trying to setup all my
extensions again, i.e.
01 = IVR
04 = Echo test
09 = Voice Mail
0061........ = Calls to Oz
26120027 = Calls to South Africa
What I've tried is the following:
if (uri =~ "sip:666@*"){
xlog("L_NOTICE", "Forwarding to Asterisk\n");
rewritehostport("voip.fast.co.nz:5070");
t_relay();
break;
};
What I would have expected is if a user dials 666 they get forwarded to the
asterisk server then the 04 etc to ech test, in turn being 66604, however it
doesnt work. If possibe; I'd like to add the direct numbers, i.e.
04 for voice mail and i'd expect something simular to this:
if (uri =~ "sip:04@*"){
xlog("L_NOTICE", "Forwarding to Asterisk\n");
rewritehostport("sip://voip.fast.co.nz:5070/04");
t_relay();
break;
};
Could someone help or point me towards a few examples, finding SER stuff
proves difficult with google, always shows asterisk stuffs.
Thanks
Barry