这个结束括号意外是什么?
function pollCreateOptions_addOption ()
{ // Opening of curly bracket 1
var highestN = 0;
$('table#options tr td fieldset').each
( // Opening of normal bracket 1
function (i, option)
{ // Opening of curly bracket 2
alert (this.attr ('name'));
{ // Closing of curly bracket 2
); // Closing of normal bracket 1
} // Closing of curly bracket 1
答案 0 :(得分:1)
$('table#options tr td fieldset').each
(
function (i, option)
{
alert (this.attr ('name'));
} // not {
);
答案 1 :(得分:1)
您应该使用结束}
而不是在此处打开{
:{ // Closing of curly bracket 2
function pollCreateOptions_addOption ()
{ // Opening of curly bracket 1
var highestN = 0;
$('table#options tr td fieldset').each
( // Opening of normal bracket 1
function (i, option)
{ // Opening of curly bracket 2
alert (this.attr ('name'));
} // Closing of curly bracket 2
); // Closing of normal bracket 1
} // Closing of curly bracket 1