日期:2014-05-16 浏览次数:20392 次
<html> <body> <div id='plst'></div> <script> var plst=document.getElementById('plst'); var count=0; plst.addEventListener("click",function(){ songList(count); }) function songList(key){ plst.innerHTML ='<ul>' \ "<li>"+key+"</li></ul>"; } </script> </body> </html>
key = '123'; s = '<ul>\ <li>'+key+'<li>\ </ul>'; alert(s)