PluginProbe
Wp-Insert / 1.2
Wp-Insert v1.2
trunk 1.0 1.1 1.2 1.2.1 1.2.2 1.3.0 1.3.1 1.3.3 1.4 1.5.0 1.5.1 1.5.2 1.5.3 1.6.0 1.6.1 1.6.2 1.7 1.7.1 1.7.2 1.7.3 1.7.4 1.7.5 1.7.6 2.0 All 63 releases
wp-insert / fckeditor / _samples / asp / sample03.asp

sample03.asp in Wp-Insert 1.2, at fckeditor/_samples/asp/sample03.asp

185 lines 3.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <%@ CodePage=65001 Language="VBScript"%>
2
3 <% Option Explicit %>
4
5 <!--
6
7 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
8
9 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
10
11 *
12
13 * == BEGIN LICENSE ==
14
15 *
16
17 * Licensed under the terms of any of the following licenses at your
18
19 * choice:
20
21 *
22
23 * - GNU General Public License Version 2 or later (the "GPL")
24
25 * http://www.gnu.org/licenses/gpl.html
26
27 *
28
29 * - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
30
31 * http://www.gnu.org/licenses/lgpl.html
32
33 *
34
35 * - Mozilla Public License Version 1.1 or later (the "MPL")
36
37 * http://www.mozilla.org/MPL/MPL-1.1.html
38
39 *
40
41 * == END LICENSE ==
42
43 *
44
45 * Sample page.
46
47 -->
48
49 <% ' You must set "Enable Parent Paths" on your web site in order this relative include to work. %>
50
51 <!-- #INCLUDE file="../../fckeditor.asp" -->
52
53 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
54
55 <html>
56
57 <head>
58
59 <title>FCKeditor - Sample</title>
60
61 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
62
63 <meta name="robots" content="noindex, nofollow">
64
65 <link href="../sample.css" rel="stylesheet" type="text/css" />
66
67 <script type="text/javascript">
68
69
70
71 function FCKeditor_OnComplete( editorInstance )
72
73 {
74
75 var oCombo = document.getElementById( 'cmbToolbars' ) ;
76
77 oCombo.value = editorInstance.ToolbarSet.Name ;
78
79 oCombo.style.visibility = '' ;
80
81 }
82
83
84
85 function ChangeToolbar( toolbarName )
86
87 {
88
89 window.location.href = window.location.pathname + "?Toolbar=" + toolbarName ;
90
91 }
92
93
94
95 </script>
96
97 </head>
98
99 <body>
100
101 <h1>FCKeditor - ASP - Sample 3</h1>
102
103 This sample shows how to change the editor toolbar.
104
105 <hr>
106
107 <table cellpadding="0" cellspacing="0" border="0">
108
109 <tr>
110
111 <td>
112
113 Select the toolbar to load:&nbsp;
114
115 </td>
116
117 <td>
118
119 <select id="cmbToolbars" onchange="ChangeToolbar(this.value);" style="VISIBILITY: hidden">
120
121 <option value="Default" selected>Default</option>
122
123 <option value="Basic">Basic</option>
124
125 </select>
126
127 </td>
128
129 </tr>
130
131 </table>
132
133 <br>
134
135 <form action="sampleposteddata.asp" method="post" target="_blank">
136
137 <%
138
139 ' Automatically calculates the editor base path based on the _samples directory.
140
141 ' This is usefull only for these samples. A real application should use something like this:
142
143 ' oFCKeditor.BasePath = '/fckeditor/' ; // '/fckeditor/' is the default value.
144
145 Dim sBasePath
146
147 sBasePath = Request.ServerVariables("PATH_INFO")
148
149 sBasePath = Left( sBasePath, InStrRev( sBasePath, "/_samples" ) )
150
151
152
153 Dim oFCKeditor
154
155 Set oFCKeditor = New FCKeditor
156
157 oFCKeditor.BasePath = sBasePath
158
159
160
161 If Request.QueryString("Toolbar") <> "" Then
162
163 oFCKeditor.ToolbarSet = Server.HTMLEncode( Request.QueryString("Toolbar") )
164
165 End If
166
167
168
169 oFCKeditor.Value = "<p>This is some <strong>sample text</strong>. You are using <a href=""http://www.fckeditor.net/"">FCKeditor</a>."
170
171 oFCKeditor.Create "FCKeditor1"
172
173 %>
174
175 <br>
176
177 <input type="submit" value="Submit">
178
179 </form>
180
181 </body>
182
183 </html>
184
185