可以直接运行HTML的HTML代码

<div id="cnblogs_post_body" class="blogpost-body ">
    <textarea id="con" style="height: 98px; width: 205px; margin: 2px;">&lt;script type="text/javascript"&gt;
alert("插入HTML代码");
&lt;/script&gt;</textarea>
<input id="btn" type="button" value="运行代码" />

猜你喜欢

转载自www.cnblogs.com/ys88/p/12501287.html