issue with apostrophes in a function with div.innerHTML
This question already has an answer here:
你可以像这样逃避你的字符串:
div.innerHTML ='<div id="link"><input type="button" onclick="location.href='http://www.google.com/';"/></div>';
链接地址: http://www.djcxy.com/p/57140.html