当前位置: 代码迷 >> ASP.NET >> 自制html编辑器?解决思路
  详细解决方案

自制html编辑器?解决思路

热度:854   发布时间:2013-02-26 00:00:00.0
自制html编辑器?
我作一简易编程器,就像CSDN回贴这个框差不多

可是按回车时候会加入一个空行,怎么把这个空行去掉?

------解决方案--------------------------------------------------------
editor=document.all.ifmParse;
editor.document.designMode= "On ";
editor.document.open();
editor.document.write( " <html> <head> <meta http-equiv=Content-Type content= 'text/html; charset=gb2312 '> <style type= 'text/css '> body {font-size: 9pt;margin: 0px;} </style> </head> <BODY bgcolor= '#FFFFFF ' MONOSPACE> <div> </div> </body> </html> ");
editor.document.write(document.all.hdnIframeParse.value);
editor.document.close();
------解决方案--------------------------------------------------------
你是用的html编辑器 而不是textbox那么
需要shift + 回车
  相关解决方案