xtemplate在html页面中 调用函数
怎么把参数传入到函数中, 各种尝试都不正确.
<a href="javascript:;" onclick="stopA({{index}}, {{title}})">
function stopA(index, title) {
console.log(index);
console.log(title);
}
这里两个输出是undefined
, 要怎么才能正确传参数? {{index}}
和 {{title}}
我确认过直接输出是有值的.