天猫双十一宋茜:这一行什么意思:html = eWebEditor_execRE("(<[^>]+) style=\"[^\"]*\"([^>]*>)", "$1 $2", html);

来源:百度文库 编辑:高考问答 时间:2024/04/24 03:32:00
整行如下:
case "STYLE": // 去除样式style=""
html = eWebEditor_execRE("(<[^>]+) style=\"[^\"]*\"([^>]*>)", "$1 $2", html);
break;

里面的style=\"[^\"]*\"([^>]*>)", 什么意思?

这段代码加入到网站局部,确影响网站全局外观(即:使网站首页发生变化):
1.<p style="MARGIN-LEFT: 10px; LINE-HEIGHT: 100%">
2.<UL dir=ltr style="MARGIN-RIGHT: 0px">
局部加入之类代码后,全局格式都改变

用ewebedit在线编辑的调用代码如下:
<!--#include file = "../plwebedit/Include/DeCode.asp"-->
<%
Response.Write eWebEditor_DeCode(sContent, "SCRIPT, STYLE")
% >
<textarea style="display:none" name=boo>显示内容</textarea>
<IFRAME ID="eWebEditor1" SRC="在线编辑器的路径/ewebeditor.asp?id=bo&style=s_popup" FRAMEBORDER="0" SCROLLING="no" WIDTH="100%" HEIGHT="500"></IFRAME>

再加入以上“1”、“2”两条代码,网站首页还是要改变。
该如何防止局部代码影响全站格式的情况?
有方法的朋友,请说一下详细步骤,谢谢!

html = eWebEditor_execRE("(<[^>]+) style=\"[^\"]*\"([^>]*>)", "$1 $2", html);
调用ewebedit这个编辑器

html = eWebEditor_execRE("(<[^>]+) style=\"[^\"]*\"([^>]*>)", "$1 $2", html);