I've downloaded the latest versions of both editor (2.3) and .net control (2.2). I am using asp.net v2.0 and C#. To use different home directories for images to upload/browse, as described in the manual http://wiki.fckeditor.net/Developer%27s ... on/ASP.Net, I need to change the UserFilesPath property. I can't use Application or web.config methods, because in my case the path will be different every time (like separate paths for users). So I use session:
protected void Page_Init(object sender, EventArgs e) {
String dir = "/vacation/users/1238350/"; //I omit the actual method call here
if (Session["FCKeditor:UserFilesPath"] == null)
Session.Add("FCKeditor:UserFilesPath", dir);
else
Session["FCKeditor:UserFilesPath"] = dir;
}
But this has no effect! I see in debugger that Session["FCKeditor:UserFilesPath"] gets its value, but images are still uploaded to /Userfiles .
I did go through the forum search, nothing really helpful on asp.net...
Thu, 07/06/2006 - 16:11
#1
RE: asp.net: UserFilesPath not set by Session[]
Never mind, guys, solved now. I put the fckeditor scripts in another web application (to IIS root), that's why Session was lost. Anyway, debugging in Visual Studio is great, and so is fck
But I have to give up an idea of having just one copy of fck and using it in all web apps when needed, I copy fck to every app now... I also don't want to amend fck sources - for future updates, or use SQL Server sessions, which are domain independent, but slow.