Hello list,
getting warning : *syntax error, unexpected '<token>'*
dialplan :
exten => pbx,n,Macro(CheckNetworkProblems,${custID})
exten => pbx,n,NoOp(status = ${STATUS})
exten =>
pbx,n,GoToIf($["${STATUS}"="congestion"]?backup:nocongestion)
CLI :
[Sep 9 12:27:07] -- Executing [pbx at cust:15]
NoOp("SIP/test13-0000002a", "status =
"congestion"") in new stack
*[Sep 9 12:27:07] WARNING[5741]: ast_expr2.fl:445 ast_yyerror:
ast_yyerror(): syntax error: syntax error, unexpected '<token>',
expecting $end; Input:
""congestion""="congestion"
^*
[Sep 9 12:27:07] WARNING[5741]: ast_expr2.fl:449 ast_yyerror: If you
have questions, please refer to doc/tex/channelvariables.tex.
[Sep 9 12:27:07] -- Executing [pbx at cust:16]
GotoIf("SIP/test13-0000002a",
"""?backup:nocongestion") in new stack
What is then the correct syntax ?!
Jonas.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://lists.digium.com/pipermail/asterisk-users/attachments/20100909/2826d13f/attachment.htm
Jonas Kellens wrote:> Hello list, > > getting warning : *syntax error, unexpected '<token>'* > > > dialplan : > > exten => pbx,n,Macro(CheckNetworkProblems,${custID}) > exten => pbx,n,NoOp(status = ${STATUS}) > exten => pbx,n,GoToIf($["${STATUS}"="congestion"]?backup:nocongestion) > > > CLI : > > [Sep 9 12:27:07] -- Executing [pbx at cust:15] > NoOp("SIP/test13-0000002a", "status = "congestion"") in new stack > *[Sep 9 12:27:07] WARNING[5741]: ast_expr2.fl:445 ast_yyerror: > ast_yyerror(): syntax error: syntax error, unexpected '<token>', > expecting $end; Input: > ""congestion""="congestion" > ^* > [Sep 9 12:27:07] WARNING[5741]: ast_expr2.fl:449 ast_yyerror: If you > have questions, please refer to doc/tex/channelvariables.tex. > [Sep 9 12:27:07] -- Executing [pbx at cust:16] > GotoIf("SIP/test13-0000002a", """?backup:nocongestion") in new stack > > > What is then the correct syntax ?! > > > Jonas. >Looks like your ${STATUS} variable contains quotes so you are effectivly double quoting it in the gotoif command.