source: companies/celepar/news_admin/templates/celepar/fckeditor/editor/filemanager/upload/cfm/config.cfm @ 763

Revision 763, 2.9 KB checked in by niltonneto, 15 years ago (diff)

Importação inicial do Expresso da Celepar

Line 
1<!---
2 * FCKeditor - The text editor for internet
3 * Copyright (C) 2003-2006 Frederico Caldeira Knabben
4 *
5 * Licensed under the terms of the GNU Lesser General Public License:
6 *              http://www.opensource.org/licenses/lgpl-license.php
7 *
8 * For further information visit:
9 *              http://www.fckeditor.net/
10 *
11 * "Support Open Source software. What about a donation today?"
12 *
13 * File Name: config.cfm
14 *      Configuration file for the ColdFusion File Uploader.
15 *
16 * File Authors:
17 *              Wim Lemmens (didgiman@gmail.com)
18--->
19
20<cfscript>
21        config = StructNew();
22                 
23        // SECURITY: You must explicitelly enable this "uploader".
24        config.enabled = false;
25       
26        // Path to uploaded files relative to the document root.
27        config.userFilesPath = "/UserFiles/";
28       
29        config.serverPath = ""; // use this to force the server path if FCKeditor is not running directly off the root of the application or the FCKeditor directory in the URL is a virtual directory or a symbolic link / junction
30               
31        config.allowedExtensions = StructNew();
32        config.deniedExtensions = StructNew();
33       
34        config.allowedExtensions["File"] = "";
35        config.deniedExtensions["File"] = "php,php2,php3,php4,php5,phtml,pwml,inc,asp,aspx,ascx,jsp,cfm,cfc,pl,bat,exe,com,dll,vbs,js,reg,cgi";
36       
37        config.allowedExtensions["Image"] = "png,gif,jpg,jpeg,bmp";
38        config.deniedExtensions["Image"] = "";
39       
40        config.allowedExtensions["Flash"] = "swf,fla";
41        config.deniedExtensions["Flash"] = "";
42</cfscript>
43
44<!--- code to maintain backwards compatibility with previous version of cfm connector --->
45<cfif isDefined("application.userFilesPath")>
46
47        <cflock scope="application" type="readonly" timeout="5">
48                <cfset config.userFilesPath = application.userFilesPath>
49        </cflock>
50
51<cfelseif isDefined("server.userFilesPath")>
52       
53        <cflock scope="server" type="readonly" timeout="5">
54                <cfset config.userFilesPath = server.userFilesPath>
55        </cflock>
56       
57</cfif>
58
59<!--- look for config struct in request, application and server scopes --->
60<cfif isDefined("request.FCKeditor") and isStruct(request.FCKeditor)>
61
62        <cfset variables.FCKeditor = request.FCKeditor>
63
64<cfelseif isDefined("application.FCKeditor") and isStruct(application.FCKeditor)>
65
66        <cflock scope="application" type="readonly" timeout="5">
67        <cfset variables.FCKeditor = duplicate(application.FCKeditor)>
68        </cflock>
69
70<cfelseif isDefined("server.FCKeditor") and isStruct(server.FCKeditor)>
71
72        <cflock scope="server" type="readonly" timeout="5">
73        <cfset variables.FCKeditor = duplicate(server.FCKeditor)>
74        </cflock>
75
76</cfif>
77
78<cfif isDefined("FCKeditor")>
79
80        <!--- copy key values from external to local config (i.e. override default config as required) --->
81        <cfscript>
82                function structCopyKeys(stFrom, stTo) {
83                        for ( key in stFrom ) {
84                                if ( isStruct(stFrom[key]) ) {
85                                        structCopyKeys(stFrom[key],stTo[key]);
86                                } else {
87                                        stTo[key] = stFrom[key];
88                                }
89                        }
90                }
91                structCopyKeys(FCKeditor, config);
92        </cfscript>
93
94</cfif>
Note: See TracBrowser for help on using the repository browser.