FckEditor2.6.4在VS2005中的使用过程
1.下载FckEditor_2.6.4.zip包和FckEditor.NET_2.6.3.zip包(怎么.net的包没有找到2.6.4呢)
2.把两个包解压。FckEditor_2.6.4.zip包解压缩的内容全部放到要使用的网站目录下面去。
3..NET包解压缩后找到“xxx\fckeditor\net\bin\Release\2.0\”目录下的“FredCK.FCKeditorV2.dll”文件,复制该文件到网站的Bin目录下。
4.将该文件直接拖放到VS的工具箱中,会多出一个FckEditor的控件。
5.在引用该控件的网页代码头部有这句话“<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
”
6.web.config文件中配置如下:
<appSettings>
<add key="FCKeditor:BasePath" value="~/fckeditor/"/>
<add key="FCKeditor:UserFilesPath" value="/Files/" />
</appSettings>
UserFilesPath的值是用户上传文件存放的目录,需要对服务器该目录有写入权限。
7.修改fckconfig.js文件
var _FileBrowserLanguage = 'aspx' ; // asp | aspx | cfm | lasso | perl | php | py
var _QuickUploadLanguage = 'aspx' ; // asp | aspx | cfm | lasso | php
8.直接把控件拖到网页中要使用的地方。
<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>无标题页</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<FCKeditorV2:FCKeditor ID="FCKeditor1" runat="server"></FCKeditorV2:FCKeditor>
</div>
</form>
</body>
</html>
9.效果图