annotate wiki/htdocs/applets/FCKeditor/editor/filemanager/connectors/cfm/cf_upload.cfm @ 5130:287faf79876f

upgrade FCKeditor from 2.6.4 to 2.6.4.1 (security update, see comments below) The security issue fixed in 2.6.4.1 had no relevance to the FCKeditor features used by MoinMoin. Thus we were not in a hurry to incorporate this and push out a new moin release with it. But as a new moin release is pending now anyway, we include the latest FCKeditor release now anyway, just to have everything up-to-date. :)
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sun, 06 Sep 2009 15:12:11 +0200
parents 1d37117f8ca6
children
rev   line source
3954
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
1 <cfsetting enablecfoutputonly="yes" showdebugoutput="no">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
2 <!---
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
3 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
4545
1d37117f8ca6 updated FCKeditor to 2.6.4
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents: 3954
diff changeset
4 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
3954
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
5 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
6 * == BEGIN LICENSE ==
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
7 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
8 * Licensed under the terms of any of the following licenses at your
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
9 * choice:
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
10 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
11 * - GNU General Public License Version 2 or later (the "GPL")
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
12 * http://www.gnu.org/licenses/gpl.html
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
13 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
14 * - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
15 * http://www.gnu.org/licenses/lgpl.html
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
16 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
17 * - Mozilla Public License Version 1.1 or later (the "MPL")
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
18 * http://www.mozilla.org/MPL/MPL-1.1.html
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
19 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
20 * == END LICENSE ==
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
21 *
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
22 * File Browser connector for ColdFusion (MX 6.0 and above).
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
23 * (based on the original CF connector by Hendrik Kramer - hk@lwd.de)
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
24 --->
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
25
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
26 <cfparam name="url.type" default="File">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
27
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
28 <!--- note: no serverPath url parameter - see config.cfm if you need to set the serverPath manually --->
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
29
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
30 <cfinclude template="config.cfm">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
31 <cfinclude template="cf_util.cfm">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
32 <cfinclude template="cf_io.cfm">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
33 <cfinclude template="cf_commands.cfm">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
34
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
35 <cffunction name="SendError" returntype="void" output="true">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
36 <cfargument name="number" required="true" type="Numeric">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
37 <cfargument name="text" required="true">
5130
287faf79876f upgrade FCKeditor from 2.6.4 to 2.6.4.1 (security update, see comments below)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents: 4545
diff changeset
38 <cfreturn SendUploadResults( "#ARGUMENTS.number#", "", "", "#ARGUMENTS.text#" )>
3954
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
39 </cffunction>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
40
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
41 <cfset REQUEST.Config = Config>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
42 <cfif find( "/", getBaseTemplatePath() ) >
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
43 <cfset REQUEST.Fs = "/">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
44 <cfelse>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
45 <cfset REQUEST.Fs = "\">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
46 </cfif>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
47
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
48 <cfif not Config.Enabled>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
49 <cfset SendUploadResults( '1', '', '', 'This file uploader is disabled. Please check the "editor/filemanager/connectors/cfm/config.cfm" file' )>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
50 </cfif>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
51
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
52 <cfset sCommand = 'QuickUpload'>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
53 <cfset sType = "File">
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
54
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
55 <cfif isDefined( "URL.Type" )>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
56 <cfset sType = URL.Type>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
57 </cfif>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
58
5130
287faf79876f upgrade FCKeditor from 2.6.4 to 2.6.4.1 (security update, see comments below)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents: 4545
diff changeset
59 <cfset sCurrentFolder = "/">
3954
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
60
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
61 <!--- Is enabled the upload? --->
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
62 <cfif not IsAllowedCommand( sCommand )>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
63 <cfset SendUploadResults( "1", "", "", "The """ & sCommand & """ command isn't allowed" )>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
64 </cfif>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
65
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
66 <!--- Check if it is an allowed type. --->
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
67 <cfif not IsAllowedType( sType )>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
68 <cfset SendUploadResults( "1", "", "", "Invalid type specified" ) >
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
69 </cfif>
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
70
6089ade226fb replace fckeditor with clean up version
Byeongweon [tasyblue@gmail.com]
parents:
diff changeset
71 <cfset FileUpload( sType, sCurrentFolder, sCommand )>