在js拼接html代码的时候,有时会遇到这样的<button onclick="test(id)"></button>代码 那么中间的方法就需要这样拼接 onclick=\"test(\'"+id+"\')\",如果拼接错误就会报上面的错