I've some code to manipulate incoming Caller-ID - so its suitable for
replying to...
[sipdef]
exten => s,1,NoOp(FWD SIP: "${CALLERIDNAME}" <${CALLERIDNUM}>)
; Alter incoming calles from pulver - add a '87'
exten => s,2,Gotoif($[${CALLERIDNAME} = ${CALLERIDNUM}]?3:4)
exten => s,3,SetCIDName(87${CALLERIDNUM})
exten => s,4,SetCIDNum(87${CALLERIDNUM})
exten => s,5,Goto(default,s,1)
When Executing the above - and I presume incoming Caller Info looks like
the name is "Mark Elkins" and the Number is "638936"...
The purpose is to prefix the number (only the number) with "87".
Sometimes, incoming CallerID data looks like --> "638936" <638936>
therefore the checking of both "Name" and <number>.
-- Executing NoOp("SIP/292951-b11f", "FWD SIP: "Mark Elkins"
<638936>") in new stack
May 12 14:36:59 WARNING[28824]: ast_expr.y:486 ast_yyerror:
ast_yyerror(): syntax error: parse error; Input:
Mark Elkins = 638936
^^^^
^
-- Executing GotoIf("SIP/292951-b11f", "Mark?3:4") in new stack
-- Goto (sipdef,s,4)
-- Executing SetCIDNum("SIP/292951-b11f", "87638936") in new stack
-- Executing Goto("SIP/292951-b11f", "default|s|1") in new stack
-- Goto (default,s,1)
What solutions are there to getting rid of the "yyerror"??
--
. . ___. .__ Posix Systems - Sth Africa. e.164 VOIP ready
/| /| / /__ [EMAIL PROTECTED] - Mark J Elkins, Cisco CCIE
/ |/ |ARK \_/ /__ LKINS Tel: +27 12 807 0590 Cell: +27 82 601 0496
_______________________________________________
Asterisk-Users mailing list
[email protected]
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users