读书人

JS怎样利用按钮实现在Text框所输入过的

发布时间: 2012-03-11 18:15:39 作者: rapoo

JS怎样利用按钮实现在Text框所输入过的内容做撤消和重做的操作
JS怎样利用按钮实现在Text框所输入过的内容做撤消和重做的操作

撤消是指上一步,不是reset按钮,重做是下一步

[解决办法]
<input type= "text ">
<input type= "button " value= "undo " onclick= "document.execCommand( 'Undo '); ">
<input type= "button " value= "redo " onclick= "document.execCommand( 'Redo '); ">

读书人网 >ASP

热点推荐