~pablocapeluto/cds-php/devel-3.1

« back to all changes in this revision

Viewing changes to FCKeditor/_samples/cfm/sample02_mx.cfm

  • Committer: pcapeluto at gmail
  • Date: 2010-08-20 17:51:08 UTC
  • Revision ID: pcapeluto@gmail.com-20100820175108-jyi8dbyj15uy9p4i
Initial import

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<cfsetting enablecfoutputonly="true">
 
2
<!---
 
3
 * FCKeditor - The text editor for internet
 
4
 * Copyright (C) 2003-2005 Frederico Caldeira Knabben
 
5
 * 
 
6
 * Licensed under the terms of the GNU Lesser General Public License:
 
7
 *              http://www.opensource.org/licenses/lgpl-license.php
 
8
 * 
 
9
 * For further information visit:
 
10
 *              http://www.fckeditor.net/
 
11
 * 
 
12
 * "Support Open Source software. What about a donation today?"
 
13
 * 
 
14
 * File Name: sample02_mx.cfm
 
15
 *      Sample page for ColdFusion MX.
 
16
 * 
 
17
 * File Authors:
 
18
 *              Hendrik Kramer (hk@lwd.de)
 
19
 *              Wim Lemmens (didgiman@gmail.com)
 
20
--->
 
21
 
 
22
<!--- ::
 
23
          * You must set the url path to the base directory for your media files (images, flash, files)
 
24
          * The best position for this variable is in your Application.cfm file
 
25
          * 
 
26
          * Possible variable scopes are:
 
27
          * <cfset APPLICATION.userFilesPath = "/UserFiles/">
 
28
          * OR:
 
29
          * <cfset SERVER.userFilesPath = "/UserFiles/">
 
30
          * OR:
 
31
          * <cfset request.FCKeditor.userFilesPath = "/UserFiles/">
 
32
          * OR:
 
33
          * <cfset application.FCKeditor.userFilesPath = "/UserFiles/">
 
34
          * OR:
 
35
          * <cfset server.FCKeditor.userFilesPath = "/UserFiles/">
 
36
          *
 
37
          * Note #1: Do _not_ set the physical directory on your server, only a path relative to your current webroot
 
38
          * Note #2: Directories will be automatically created
 
39
          :: --->
 
40
 
 
41
<cfoutput>
 
42
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 
43
<html>
 
44
<head>
 
45
        <title>FCKeditor - Sample</title>
 
46
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 
47
        <meta name="robots" content="noindex, nofollow">
 
48
        <link href="../sample.css" rel="stylesheet" type="text/css" />
 
49
</head>
 
50
<body>
 
51
<h1>FCKeditor - ColdFusion Component (CFC) - Sample 2</h1>
 
52
 
 
53
This sample displays a normal HTML form with a FCKeditor with full features enabled; invoked by a ColdFusion Component.<br>
 
54
ColdFusion is a registered trademark and product of <a href="http://www.macromedia.com/software/coldfusion/" target="_blank">Macromedia, Inc</a>.
 
55
<hr>
 
56
 
 
57
<form method="POST" action="#cgi.script_name#">
 
58
</cfoutput>
 
59
 
 
60
<cfif listFirst( server.coldFusion.productVersion ) LT 6>
 
61
        <cfoutput><br><em style="color: red;">This sample works only with a ColdFusion MX server and higher, because it uses some advantages of this version.</em></cfoutput>
 
62
        <cfabort>
 
63
</cfif>
 
64
 
 
65
<cfscript>
 
66
        // Calculate basepath for FCKeditor. It's in the folder right above _samples
 
67
        basePath = Left(cgi.script_name, FindNoCase('_samples', cgi.script_name)-1);
 
68
 
 
69
        fckEditor = createObject("component", "#basePath#fckeditor");
 
70
        fckEditor.instanceName  = "myEditor";
 
71
        fckEditor.value                 = 'This is some sample text. You are using <a href="http://fckeditor.net/" target="_blank">FCKeditor</a>.';
 
72
        fckEditor.basePath              = basePath;
 
73
        fckEditor.width                 = "100%";
 
74
        fckEditor.height                = 300;
 
75
        fckEditor.create(); // create the editor.
 
76
</cfscript>
 
77
 
 
78
<cfoutput>
 
79
<br />
 
80
<input type="submit" value="Submit">
 
81
<br />
 
82
</cfoutput>
 
83
 
 
84
<cfdump 
 
85
        var="#FORM#" 
 
86
        label="Dump of FORM Variables"
 
87
>
 
88
 
 
89
<cfoutput></form></body></html></cfoutput>
 
90
 
 
91
<cfsetting enablecfoutputonly="false">
 
 
b'\\ No newline at end of file'