当前位置: 首页 > 网站建设 > 正文

FCK编辑器实在是太臃肿,我一般都不使用,除非需要使用表格,毕竟UBB没有表格功能,PJ4又迟迟不发布,所以就只能自己动手更换编辑器了。之前也尝试过,不知道为什么最后放弃了,今天心血来潮,就又试着更换了一下,这次还是比较顺利,能够完美的兼容,只是那个附件上传功能,我就没有去折腾它了,毕竟我不使用附件功能。我的空间实在是太小,放图片什么的都太奢侈了,所以我的图片都是放在photobucket的图床上面,速度相当的快,而且管理方便,何乐而不为呢。

下面我把我的方法共享出来,也许你会需要,顺便也自己备份一下。

-------------华丽的分割线-------------

1、将下载的xheditor.js以及xheditor_emot、xheditor_plugins和xheditor_skin三个文件夹上传到根目录下的xheditor文件夹。

2、打开header.asp文件

在之前添加代码:

<script type="text/javascript" src="common/jquery.js"></script>
<script type="text/javascript" src="xheditor/xheditor.js"></script>

<script type="text/javascript" src="common/jquery.js"></script>
<script type="text/javascript" src="xheditor/xheditor.js"></script>

注:因为我之前已经上传过jquery.js文件,所以这次直接调用,如果没有,请上传到相关目录。

3、打开blogpost.asp文件

找到代码:

<label title="UBB编辑器" for="ET1" accesskey="U"><input type="radio" id="ET1" name="log_editType" value="1" checked="checked" />UBBeditor</label>
<label title="FCK在线编辑器" for="ET2" accesskey="K"><input name="log_editType" type="radio" id="ET2" value="0" />FCKeditor</label>

把以上代码修改为:

<label title="UBB编辑器" for="ET1" accesskey="U"><input type="radio" id="ET1" name="log_editType" value="1" checked="checked" />UBBeditor</label>
<label title="xhEditor编辑器" for="ET2" accesskey="X"><input name="log_editType" type="radio" id="ET2" value="0" />xhEditor</label>

找到代码:

<%
if log_editType=0 then
Dim sBasePath
sBasePath = "fckeditor/"
Dim oFCKeditor
Set oFCKeditor = New FCKeditor
oFCKeditor.BasePath = sBasePath
oFCKeditor.Config("AutoDetectLanguage") = False
oFCKeditor.Config("DefaultLanguage")    = "zh-cn"
oFCKeditor.Value = ""
oFCKeditor.Create "Message"
else
UBB_TextArea_Height="200px;"
UBB_AutoHidden=False
UBBeditor("Message")
end if
%>

 

把以上代码修改为:

<%
If log_editType = 0 Then
%>
<textarea name="message" class="xheditor-mfull" style="width: 99%; height: 250px; display: none;"></textarea><input type="text" id="xhe0_fixffcursor" style="position:absolute;display:none;"><span id="xhe0_container" class="xhe_default" style=""><table cellspacing="0" cellpadding="0" class="xheLayout" style="width:99%;height:250px;" role="presentation"><tbody><tr><td id="xhe0_Tool" class="xheTool" unselectable="on" style="height:1px;" role="presentation"><span class="xheGStart"></span><span><a href="#" title="剪切 (Ctrl+X)" cmd="Cut" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnCut" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">剪切 (Ctrl+X)</span></a></span><span><a href="#" title="复制 (Ctrl+C)" cmd="Copy" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnCopy" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">复制 (Ctrl+C)</span></a></span><span><a href="#" title="粘贴 (Ctrl+V)" cmd="Paste" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPaste" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">粘贴 (Ctrl+V)</span></a></span><span><a href="#" title="粘贴文本" cmd="Pastetext" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPastetext" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">粘贴文本</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="段落标签" cmd="Blocktag" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBlocktag" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">段落标签</span></a></span><span><a href="#" title="字体" cmd="Fontface" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontface" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体</span></a></span><span><a href="#" title="字体大小" cmd="FontSize" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontSize" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体大小</span></a></span><span><a href="#" title="加粗 (Ctrl+B)" cmd="Bold" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBold" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">加粗 (Ctrl+B)</span></a></span><span><a href="#" title="斜体 (Ctrl+I)" cmd="Italic" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnItalic" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">斜体 (Ctrl+I)</span></a></span><span><a href="#" title="下划线 (Ctrl+U)" cmd="Underline" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnderline" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">下划线 (Ctrl+U)</span></a></span><span><a href="#" title="删除线" cmd="Strikethrough" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnStrikethrough" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除线</span></a></span><span><a href="#" title="字体颜色" cmd="FontColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体颜色</span></a></span><span><a href="#" title="背景颜色" cmd="BackColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBackColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">背景颜色</span></a></span><span><a href="#" title="全选 (Ctrl+A)" cmd="SelectAll" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnSelectAll" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">全选 (Ctrl+A)</span></a></span><span><a href="#" title="删除文字格式" cmd="Removeformat" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnRemoveformat" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除文字格式</span></a></span><span class="xheGEnd"></span>
<span class="xheGStart"></span><span><a href="#" title="对齐" cmd="Align" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAlign" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">对齐</span></a></span><span><a href="#" title="列表" cmd="List" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnList" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">列表</span></a></span><span><a href="#" title="减少缩进" cmd="Outdent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnOutdent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">减少缩进</span></a></span><span><a href="#" title="增加缩进" cmd="Indent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnIndent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">增加缩进</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="超链接 (Ctrl+L)" cmd="Link" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnLink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">超链接 (Ctrl+L)</span></a></span><span><a href="#" title="取消超链接" cmd="Unlink" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnlink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">取消超链接</span></a></span><span><a href="#" title="锚点" cmd="Anchor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAnchor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">锚点</span></a></span><span><a href="#" title="图片" cmd="Img" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnImg" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">图片</span></a></span><span><a href="#" title="Flash动画" cmd="Flash" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFlash" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">Flash动画</span></a></span><span><a href="#" title="多媒体文件" cmd="Media" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnMedia" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">多媒体文件</span></a></span><span><a href="#" title="插入水平线" cmd="Hr" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnHr" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">插入水平线</span></a></span><span><a href="#" title="表情" cmd="Emot" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnEmot" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表情</span></a></span><span><a href="#" title="表格" cmd="Table" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnTable" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表格</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="源代码" cmd="Source" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnSource" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">源代码</span></a></span><span><a href="#" title="预览" cmd="Preview" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPreview" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">预览</span></a></span><span><a href="#" title="打印 (Ctrl+P)" cmd="Print" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPrint" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">打印 (Ctrl+P)</span></a></span><span><a href="#" title="全屏编辑 (Esc)" cmd="Fullscreen" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFullscreen" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">全屏编辑 (Esc)</span></a></span><span><a href="#" title="关于 xhEditor" cmd="About" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAbout" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">关于 xhEditor</span></a></span><span class="xheGEnd"></span>
</td></tr><tr><td id="xhe0_iframearea" class="xheIframeArea" role="presentation" style="height: 206px;"><iframe frameborder="0" id="xhe0_iframe" src="javascript:;" style="width:100%;"></iframe></td></tr></tbody></table></span>
<%
Else
UBB_TextArea_Height = "200px;"
UBB_AutoHidden = False
UBBeditor("Message")
End If
%>

 

找到代码:

<%
if log_editType=0 then
Dim oFCKeditor1
Set oFCKeditor1 = New FCKeditor
oFCKeditor1.BasePath = sBasePath
oFCKeditor1.Height="150"
oFCKeditor1.ToolbarSet="Basic"
oFCKeditor1.Config("AutoDetectLanguage") = False
oFCKeditor1.Config("DefaultLanguage")    = "zh-cn"
oFCKeditor1.Value = ""
oFCKeditor1.Create "log_Intro"
else
%>
<textarea name="log_Intro" class="editTextarea" style="width:99%;height:120px;"></textarea>
<%
end if
%>

 

把以上代码修改为:

<%
If log_editType = 0 Then
%>
<textarea name="log_Intro" class="xheditor-simple" style="width: 99%; height: 150px; display: none;"></textarea><input type="text" id="xhe1_fixffcursor" style="position:absolute;display:none;"><span id="xhe1_container" class="xhe_default" style=""><table cellspacing="0" cellpadding="0" class="xheLayout" style="width:99%;height:150px;" role="presentation"><tbody><tr><td id="xhe1_Tool" class="xheTool" unselectable="on" style="height:1px;" role="presentation"><span class="xheGStart"></span><span><a href="#" title="段落标签" cmd="Blocktag" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBlocktag" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">段落标签</span></a></span><span><a href="#" title="字体" cmd="Fontface" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontface" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体</span></a></span><span><a href="#" title="字体大小" cmd="FontSize" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontSize" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体大小</span></a></span><span><a href="#" title="加粗 (Ctrl+B)" cmd="Bold" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBold" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">加粗 (Ctrl+B)</span></a></span><span><a href="#" title="斜体 (Ctrl+I)" cmd="Italic" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnItalic" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">斜体 (Ctrl+I)</span></a></span><span><a href="#" title="下划线 (Ctrl+U)" cmd="Underline" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnderline" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">下划线 (Ctrl+U)</span></a></span><span><a href="#" title="删除线" cmd="Strikethrough" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnStrikethrough" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除线</span></a></span><span><a href="#" title="字体颜色" cmd="FontColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体颜色</span></a></span><span><a href="#" title="背景颜色" cmd="BackColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBackColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">背景颜色</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="对齐" cmd="Align" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAlign" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">对齐</span></a></span><span><a href="#" title="列表" cmd="List" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnList" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">列表</span></a></span><span><a href="#" title="减少缩进" cmd="Outdent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnOutdent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">减少缩进</span></a></span><span><a href="#" title="增加缩进" cmd="Indent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnIndent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">增加缩进</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="超链接 (Ctrl+L)" cmd="Link" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnLink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">超链接 (Ctrl+L)</span></a></span><span><a href="#" title="图片" cmd="Img" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnImg" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">图片</span></a></span><span><a href="#" title="表情" cmd="Emot" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnEmot" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表情</span></a></span><span><a href="#" title="关于 xhEditor" cmd="About" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAbout" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">关于 xhEditor</span></a></span><span class="xheGEnd"></span>
</td></tr><tr><td id="xhe1_iframearea" class="xheIframeArea" role="presentation" style="height: 128px;"><iframe frameborder="0" id="xhe1_iframe" src="javascript:;" style="width:100%;"></iframe></td></tr></tbody></table></span>
<%
Else
%>
<textarea name="log_Intro" class="editTextarea" style="width:99%;height:120px;"></textarea>
<%
End If
%>

 

4、打开blogedit.asp文件

找到代码:

<%
if log_editType=0 then
Dim sBasePath
sBasePath = "fckeditor/"
Dim oFCKeditor
Set oFCKeditor = New FCKeditor
oFCKeditor.BasePath = sBasePath
oFCKeditor.Config("AutoDetectLanguage") = False
oFCKeditor.Config("DefaultLanguage")    = "zh-cn"
oFCKeditor.Value = UnCheckStr(lArticle.logMessage)
oFCKeditor.Create "Message"
else
UBB_TextArea_Height="200px;"
UBB_AutoHidden=False
UBB_Msg_Value=UBBFilter(UnCheckStr(lArticle.logMessage))
UBBeditor("Message")
end if
%>

 

把以上代码修改为:

<%
If log_editType = 0 Then
%>
<textarea name="message" class="xheditor-mfull" style="width: 99%; height: 250px; display: none;"><%=HTMLDecode(UnCheckStr(lArticle.logMessage))%></textarea><input type="text" id="xhe2_fixffcursor" style="position:absolute;display:none;"><span id="xhe2_container" class="xhe_default" style=""><table cellspacing="0" cellpadding="0" class="xheLayout" style="width:99%;height:250px;" role="presentation"><tbody><tr><td id="xhe2_Tool" class="xheTool" unselectable="on" style="height:1px;" role="presentation"><span class="xheGStart"></span><span><a href="#" title="剪切 (Ctrl+X)" cmd="Cut" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnCut" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">剪切 (Ctrl+X)</span></a></span><span><a href="#" title="复制 (Ctrl+C)" cmd="Copy" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnCopy" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">复制 (Ctrl+C)</span></a></span><span><a href="#" title="粘贴 (Ctrl+V)" cmd="Paste" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPaste" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">粘贴 (Ctrl+V)</span></a></span><span><a href="#" title="粘贴文本" cmd="Pastetext" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPastetext" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">粘贴文本</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="段落标签" cmd="Blocktag" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBlocktag" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">段落标签</span></a></span><span><a href="#" title="字体" cmd="Fontface" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontface" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体</span></a></span><span><a href="#" title="字体大小" cmd="FontSize" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontSize" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体大小</span></a></span><span><a href="#" title="加粗 (Ctrl+B)" cmd="Bold" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBold" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">加粗 (Ctrl+B)</span></a></span><span><a href="#" title="斜体 (Ctrl+I)" cmd="Italic" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnItalic" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">斜体 (Ctrl+I)</span></a></span><span><a href="#" title="下划线 (Ctrl+U)" cmd="Underline" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnderline" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">下划线 (Ctrl+U)</span></a></span><span><a href="#" title="删除线" cmd="Strikethrough" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnStrikethrough" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除线</span></a></span><span><a href="#" title="字体颜色" cmd="FontColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体颜色</span></a></span><span><a href="#" title="背景颜色" cmd="BackColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBackColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">背景颜色</span></a></span><span><a href="#" title="全选 (Ctrl+A)" cmd="SelectAll" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnSelectAll" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">全选 (Ctrl+A)</span></a></span><span><a href="#" title="删除文字格式" cmd="Removeformat" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnRemoveformat" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除文字格式</span></a></span><span class="xheGEnd"></span>
<span class="xheGStart"></span><span><a href="#" title="对齐" cmd="Align" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAlign" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">对齐</span></a></span><span><a href="#" title="列表" cmd="List" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnList" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">列表</span></a></span><span><a href="#" title="减少缩进" cmd="Outdent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnOutdent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">减少缩进</span></a></span><span><a href="#" title="增加缩进" cmd="Indent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnIndent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">增加缩进</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="超链接 (Ctrl+L)" cmd="Link" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnLink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">超链接 (Ctrl+L)</span></a></span><span><a href="#" title="取消超链接" cmd="Unlink" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnlink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">取消超链接</span></a></span><span><a href="#" title="锚点" cmd="Anchor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAnchor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">锚点</span></a></span><span><a href="#" title="图片" cmd="Img" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnImg" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">图片</span></a></span><span><a href="#" title="Flash动画" cmd="Flash" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFlash" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">Flash动画</span></a></span><span><a href="#" title="多媒体文件" cmd="Media" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnMedia" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">多媒体文件</span></a></span><span><a href="#" title="插入水平线" cmd="Hr" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnHr" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">插入水平线</span></a></span><span><a href="#" title="表情" cmd="Emot" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnEmot" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表情</span></a></span><span><a href="#" title="表格" cmd="Table" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnTable" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表格</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="源代码" cmd="Source" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnSource" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">源代码</span></a></span><span><a href="#" title="预览" cmd="Preview" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPreview" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">预览</span></a></span><span><a href="#" title="打印 (Ctrl+P)" cmd="Print" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnPrint" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">打印 (Ctrl+P)</span></a></span><span><a href="#" title="全屏编辑 (Esc)" cmd="Fullscreen" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFullscreen" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">全屏编辑 (Esc)</span></a></span><span><a href="#" title="关于 xhEditor" cmd="About" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAbout" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">关于 xhEditor</span></a></span><span class="xheGEnd"></span>
</td></tr><tr><td id="xhe2_iframearea" class="xheIframeArea" role="presentation" style="height: 206px;"><iframe frameborder="0" id="xhe2_iframe" src="javascript:;" style="width:100%;"></iframe></td></tr></tbody></table></span>
<%
Else
UBB_TextArea_Height = "200px;"
UBB_AutoHidden = False
UBB_Msg_Value = UBBFilter(UnCheckStr(lArticle.logMessage))
UBBeditor("Message")
End If
%>

 

找到代码:

<%
if log_editType=0 then
Dim oFCKeditor1
Set oFCKeditor1 = New FCKeditor
oFCKeditor1.BasePath = sBasePath
oFCKeditor1.Height="150"
oFCKeditor1.ToolbarSet="Basic"
oFCKeditor1.Config("AutoDetectLanguage") = False
oFCKeditor1.Config("DefaultLanguage")    = "zh-cn"
oFCKeditor1.Value = UnCheckStr(lArticle.logIntro)
oFCKeditor1.Create "log_Intro"
else
%>
<textarea name="log_Intro" class="editTextarea" style="width:99%;height:120px;"><%=UBBFilter(HTMLDecode(UnCheckStr(lArticle.logIntro)))%></textarea>
<%
end if
%>

 

把以上代码修改为:

<%
If log_editType = 0 Then
%>
<textarea name="log_Intro" class="xheditor-simple" style="width: 99%; height: 150px; display: none;"><%=HTMLDecode(UnCheckStr(lArticle.logIntro))%></textarea><input type="text" id="xhe3_fixffcursor" style="position:absolute;display:none;"><span id="xhe3_container" class="xhe_default" style=""><table cellspacing="0" cellpadding="0" class="xheLayout" style="width:99%;height:150px;" role="presentation"><tbody><tr><td id="xhe3_Tool" class="xheTool" unselectable="on" style="height:1px;" role="presentation"><span class="xheGStart"></span><span><a href="#" title="段落标签" cmd="Blocktag" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBlocktag" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">段落标签</span></a></span><span><a href="#" title="字体" cmd="Fontface" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontface" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体</span></a></span><span><a href="#" title="字体大小" cmd="FontSize" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontSize" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体大小</span></a></span><span><a href="#" title="加粗 (Ctrl+B)" cmd="Bold" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBold" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">加粗 (Ctrl+B)</span></a></span><span><a href="#" title="斜体 (Ctrl+I)" cmd="Italic" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnItalic" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">斜体 (Ctrl+I)</span></a></span><span><a href="#" title="下划线 (Ctrl+U)" cmd="Underline" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnUnderline" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">下划线 (Ctrl+U)</span></a></span><span><a href="#" title="删除线" cmd="Strikethrough" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnStrikethrough" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">删除线</span></a></span><span><a href="#" title="字体颜色" cmd="FontColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnFontColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">字体颜色</span></a></span><span><a href="#" title="背景颜色" cmd="BackColor" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnBackColor" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">背景颜色</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="对齐" cmd="Align" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAlign" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">对齐</span></a></span><span><a href="#" title="列表" cmd="List" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnList" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">列表</span></a></span><span><a href="#" title="减少缩进" cmd="Outdent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnOutdent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">减少缩进</span></a></span><span><a href="#" title="增加缩进" cmd="Indent" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnIndent" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">增加缩进</span></a></span><span class="xheGEnd"></span><span class="xheSeparator"></span><span class="xheGStart"></span><span><a href="#" title="超链接 (Ctrl+L)" cmd="Link" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnLink" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">超链接 (Ctrl+L)</span></a></span><span><a href="#" title="图片" cmd="Img" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnImg" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">图片</span></a></span><span><a href="#" title="表情" cmd="Emot" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnEmot" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">表情</span></a></span><span><a href="#" title="关于 xhEditor" cmd="About" class="xheButton xheEnabled" tabindex="-1" role="button"><span class="xheIcon xheBtnAbout" unselectable="on" style="font-size:0;color:transparent;text-indent:-999px;">关于 xhEditor</span></a></span><span class="xheGEnd"></span>
</td></tr><tr><td id="xhe3_iframearea" class="xheIframeArea" role="presentation" style="height: 128px;"><iframe frameborder="0" id="xhe3_iframe" src="javascript:;" style="width:100%;"></iframe></td></tr></tbody></table></span>
<%
Else
%>
<textarea name="log_Intro" class="editTextarea" style="width:99%;height:120px;"><%=UBBFilter(HTMLDecode(UnCheckStr(lArticle.logIntro)))%></textarea>
<%
End If
%>

登顶珠峰,目前有 12 块垫脚石

  1. Lvtu
    6楼
    Lvtu

    春哥,xhEditor模式下日志中需要插入代码时,具体是怎么编辑的?例如你的日志中的代码是怎么插入进去的,然后使用SyntaxHihglighter高亮!

    • 上善若水
      上善若水

      可以自己添加高亮功能,网上有教程的。

  2. Lvtu
    5楼
    Lvtu

    我现用的CKeditor, 有时间也试一下这个东东。。。

    • 上善若水
      上善若水

      FCK太臃肿了,网络不好的情况下,很难加载成功。

  3. Lvtu
    4楼
    Lvtu

    春哥,你现在也用的这个?
    日志中的代码高亮是怎么折腾的?

    • 上善若水
      上善若水

      我现在发表日志都是用的xhEditor,已经彻底把UBB给抛弃了,代码高亮用的SyntaxHihglighter高亮插件。

  4. Lvtu
    地板
    Lvtu

    PJ4用的也是这个东东,EE刚加了图片防盗链。。。

    • 上善若水
      上善若水

      恩。这个编辑器确实比较不错,加载速度也相当OK。就是感觉表格功能不够强大。

  5. liaokai
    板凳
    liaokai

    [qq02]pj4内侧群里前段时间说pj4马上出,正在调试,打算参加内侧呢,呵呵

    • 上善若水
      上善若水

      EE正在赶呢,希望尽快吧,时不我待,毕竟ZB已经出了2.0。

  6. 数学人
    沙发
    数学人

    博主,PJ4还会出吗?我见Zblog都有新版了。并且原来的pJ3有些功能已落后了

    • 上善若水
      上善若水

      EE的微博一直在更新PJ4的信息,你可以关注下。

发表评论

gravatar