PHP:解析错误:意外的 T_DOUBLE_ARROW
我的代码给了我错误
解析错误:语法错误,意外的 T_DOUBLE_ARROW,需要 ')' 第 208 行
我不断收到此消息,但它看起来正确吗? 208号线是第二个下来的。
array( "name" => "Colour Scheme",
"desc" => "Select the colour scheme for the theme",
"id" => $shortname."_color_scheme",
"type" => "select",
"options" => array("blue", "red", "green"),
"std" => "blue"),
请指教!
谢谢
My code gives me the error
Parse error: syntax error, unexpected T_DOUBLE_ARROW, expecting ')' line 208
I keep getting this but it looks correct? Line 208 which is the second down.
array( "name" => "Colour Scheme",
"desc" => "Select the colour scheme for the theme",
"id" => $shortname."_color_scheme",
"type" => "select",
"options" => array("blue", "red", "green"),
"std" => "blue"),
please advise!
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
T_DOUBLE_ARROW
是=>
的标记,因此您的标记出现在解析器不期望的地方。除了结尾的
,
之外,您发布的代码没有错误。T_DOUBLE_ARROW
is the token for=>
, so you have one which appears somewhere the parser doesn't expect it.Besides that trailing
,
, there is no error with the code you posted.我敢打赌 Jonah 是正确的,并且错误出现在该数组上方的行中。从尾随
,
的上下文来看,我敢打赌这是一个多维数组。如果您在数组周围包含代码,我敢打赌问题就出在上面的行上。
祝你好运。
My bet is that Jonah is correct and that the error in the line above this array. From the context of the trailing
,
I bet this is a mutli-dimensional array.If you include the code around your array I bet the problem is the line above.
Good luck.