到官方网站去下载了V2.6.4.1,其它方面都可以使用,就是上传图片无论如何就是有问题,上传不了图片,配置如下,
<appSettings>
<add key="cn.com.webxml.www.WeatherWebService" value="http://www.webxml.com.cn/WebServices/WeatherWebService.asmx"/>
<add key="FCKeditor:BasePath" value="~/fckeditor/"></add>
<add key="FCKeditor:UserFilesPath" value="~/upload"></add>
</appSettings>请问如何配置才能打开并上传浏览图片?说明,我的是VS2008
<appSettings>
<add key="cn.com.webxml.www.WeatherWebService" value="http://www.webxml.com.cn/WebServices/WeatherWebService.asmx"/>
<add key="FCKeditor:BasePath" value="~/fckeditor/"></add>
<add key="FCKeditor:UserFilesPath" value="~/upload"></add>
</appSettings>请问如何配置才能打开并上传浏览图片?说明,我的是VS2008
解决方案 »
- asp.net 点击File控件 如何实现选择图片立刻上传并预览?
- iis问题
- 推荐一个非常好的学习.NET视频网址
- 再次发贴求一个正则表达式,把"file:///D:/web images/map/zs.gif"这样的字符串提取出来
- 请问服务器端控件 与下面id=okok runat=server 的控件的差别有哪里?
- DateGrid的模版列问题?
- 如何验证文本框内的字符(textbox1.text)是否为时间格式?
- 我是.net的初学者,我怎样快速上手?(151434776)
- !!获取文件名问题!!急用,在线等
- 调用sQlserver的命令对数据库进行备份和恢复。且备份及恢复的路径仅限制与服务器。大虾请救命...
- Textbox 宽度问题
- 有问题请教!!
用最简单的语言描述一下。其它配置和优化就不说了,只说怎么让它在asp.net环境下能用,能上传。
1、下载文件 http://www.fckeditor.net/download
FCKeditor_2.4.1.zip 和 FCKeditor.Net_2.2.zip
这是目前最新的版本。 FCKeditor_2.4.1.zip 为fckeditor的页面文件 FCKeditor.Net_2.2.zip 是asp.net下的上传用的 dll控件和其源文件
2、 解压FCKeditor_2.4.1.zip 到网站根目录下的 fckeditor中,解压FCKeditor.Net_2.2.zip 将其目录 FCKeditor.Net_2.2\bin\Release中的 FredCK.FCKeditorV2.dll 复制到 根目录的/bin/下
3、打开/fckeditor/fckconfig.js 修改两行代码
var _FileBrowserLanguage = 'aspx' ;
var _QuickUploadLanguage = 'aspx' ;
把默认的asp语言改成aspx
4、这就算行了,开始用吧。根目录下建立test.aspx,其代码如下:
<%@ Page language="c#" AutoEventWireup="false" validateRequest=false%>
<%@ Register TagPrefix="FCKeditorV2" Namespace="FredCK.FCKeditorV2" Assembly="FredCK.FCKeditorV2" %>
<form id="Form1" method="post" runat="server">
<FCKeditorV2:FCKeditor id="content" runat="server"></FCKeditorV2:FCKeditor>
</form>
应该就ok了,可以上传。默认传到根目录的/UserFiles/下,不用自己建,它自己会建。
如果要改上传目录,需要修改FCKeditor.Net_2.2.zip这个包里的.net源文件。修改FileWorkerBase.cs ,改一下26行
private const string DEFAULT_USER_FILES_PATH = "/UserFiles/" ;
重新编译一下,生成新的dll,复制过去,应该就OK了。(这个我没试,应该没问题)
另外,说一句,fckeditor是很灵活的,可以做很多高级的设置。
{
////这里要设置为真,默认的是false return true;
}试试
{
return true;
}
设置了的,问题依旧,
这是我的:<appSettings>
<add key="FCKeditor:BasePath" value="~/fckeditor/"/>
<add key="FCKeditor:UserFilesPath" value="/ChangJieSystem/UserFiles"/>
</appSettings>注意这里:value="/ChangJieSystem/UserFiles"/ChangJieSystem 这是你的工程名称。
条件是 FCKeditor这个东西必须在根目录下
<add key="FCKeditor:BasePath" value="~/fckeditor/"> </add>
<add key="FCKeditor:UserFilesPath" value="~/upload"> </add>
</appSettings> value="~/upload"> 这个多半设置是不对的,请问应该怎么修改?
我把这里改为:(by为发布后的虚拟目录名称)
<appSettings>
<add key="FCKeditor:BasePath" value="~/fckeditor/"> </add>
<add key="FCKeditor:UserFilesPath" value="/by/upload"> </add>
</appSettings>
问题依旧。
CheckAuthentication() 最好返回 true
SetConfig()中的 Userfilespath; 默认是取web.config的值,若无则取这里的;4、注意代码:TypeConfig[ "Image" ].QuickUploadPath..这里是可以让你在快速上传时上传到指定的
文件夹。5、若使用在快速上传时出现长久停滞则说明权限问题,要引入fck的类库原文件,解决方法
http://www.cnblogs.com/wangpei/archive/2009/06/27/1512228.html6、注意fckconfig.js 中
var _FileBrowserLanguage = 'aspx' ;
var _QuickUploadLanguage = 'aspx' ;
是否选择了 "aspx"
1.fckconfig.js文件中把
var _FileBrowserLanguage = 'php' ; // asp | aspx | cfm | lasso | perl | php | py
var _QuickUploadLanguage = 'php' ; // asp | aspx | cfm | lasso | perl | php | py中的php改成aspx2.把fckeditor\editor\filemanager\connectors\aspx中的config.ascx文件中的
private bool CheckAuthentication()
{
// WARNING : DO NOT simply return "true". By doing so, you are allowing
// "anyone" to upload and list the files in your server. You must implement
// some kind of session validation here. Even something very simple as...
//
// return ( Session[ "IsAuthorized" ] != null && (bool)Session[ "IsAuthorized" ] == true );
//
// ... where Session[ "IsAuthorized" ] is set to "true" as soon as the
// user logs in your system. return false;
}
return false改成return true这样就可以了....
如果服务器上面也不行,那多半就是路径设计问题了,没有用过fck,自己研究研究。
推荐使用eWebEditor,fck复制word文档的时候要复制两次,听麻烦的。不知道现在有没有更新了。
<add key="FCKeditor:BasePath" value="~/fckeditor/"> </add>
<add key="FCKeditor:UserFilesPath" value="~/upload"> </add>
</appSettings>其实就是这个地方设置有问题,其它地方反复检查了没问题,怎么修改?
<add key="FCKeditor:BasePath" value="~/fckeditor/"/>
<add key="FCKeditor:UserFilesPath" value="Files/"/>
</appSettings>
我用的这样的 是可以的
<add key="FCKeditor:UserFilesPath" value="/UserFiles/"></add>
<add key="FCKeditor:BasePath" value="~/fckeditor/"></add>
</appSettings>目前可以上传目录,但是点击那个图像属性的【浏览服务器】时提示:“找不到网页”,不知道大家遇到这个问题没得?