|
<br><br><div class="msgbody"><div class="msgheader"><div class="right"><a href="###" class="smalltxt" onclick="copycode($('code0'));">[Copy to clipboard]</a> <a class="smalltxt" href="###" onclick="toggle_collapse('code0');">[ <span id="code0_symbol">-</span> ]</a></div>CODE:</div><div class="msgborder" id="code0"><TABLE class=link01 cellSpacing=0 cellPadding=0 width="100%" border=0><br /> <TBODY><br /> <TR><br /> <TD bgColor=#bcccdf height=20><br /> <DIV align=center>HTML代码转换成JS脚本</DIV></TD></TR><br /> <TR><br /> <TD align=middle><br /> <DIV align=center>请将html代码复制到下面框中: <BR><TEXTAREA id=oSource onpropertychange=change() rows=10 cols=100></TEXTAREA> <br /> <BR>下面框中是相应的JS代码: <BR><TEXTAREA id=oResult ondblclick='this.select();oResult.createTextRange().execCommand("Copy")' title=双击复制 rows=10 cols=100></TEXTAREA> <br /> </TEXTAREA><BR><br /> <SCRIPT language=JavaScript><br />function change(){<br />oResult.value="document.writeln(\""+oSource.value.replace(/\\/g,"\\\\").replace(/\//g,"\\/").replace(/\'/g,"\\\'").replace(/\"/g,"\\\"").split('\r\n').join("\");\ndocument.writeln(\"")+"\")"<br />} </SCRIPT><br /></DIV></TD></TR></TBODY></TABLE></div></div><br> |
|