Subversion Repositories Applications.papyrus

Rev

Rev 1688 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1688 Rev 1921
Line 1... Line 1...
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2
<!--
2
<!--
3
 * FCKeditor - The text editor for internet
3
 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
4
 * Copyright (C) 2003-2006 Frederico Caldeira Knabben
4
 * Copyright (C) 2003-2008 Frederico Caldeira Knabben
-
 
5
 *
-
 
6
 * == BEGIN LICENSE ==
5
 * 
7
 *
6
 * Licensed under the terms of the GNU Lesser General Public License:
8
 * Licensed under the terms of any of the following licenses at your
7
 * 		http://www.opensource.org/licenses/lgpl-license.php
9
 * choice:
8
 * 
10
 *
9
 * For further information visit:
11
 *  - GNU General Public License Version 2 or later (the "GPL")
10
 * 		http://www.fckeditor.net/
12
 *    http://www.gnu.org/licenses/gpl.html
11
 * 
13
 *
12
 * "Support Open Source software. What about a donation today?"
14
 *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
-
 
15
 *    http://www.gnu.org/licenses/lgpl.html
13
 * 
16
 *
14
 * File Name: fckeditor.html
17
 *  - Mozilla Public License Version 1.1 or later (the "MPL")
15
 * 	Main page that holds the editor.
18
 *    http://www.mozilla.org/MPL/MPL-1.1.html
16
 * 
19
 *
17
 * File Authors:
20
 * == END LICENSE ==
-
 
21
 *
18
 * 		Frederico Caldeira Knabben (fredck@fckeditor.net)
22
 * Main page that holds the editor.
19
-->
23
-->
20
<html xmlns="http://www.w3.org/1999/xhtml">
24
<html>
21
<head>
25
<head>
22
	<title>FCKeditor</title>
26
	<title>FCKeditor</title>
23
	<meta name="robots" content="noindex, nofollow" />
27
	<meta name="robots" content="noindex, nofollow">
24
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
28
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
25
	<meta http-equiv="Cache-Control" content="public" />
29
	<meta http-equiv="Cache-Control" content="public">
26
	<script type="text/javascript">
30
	<script type="text/javascript">
Line -... Line 31...
-
 
31
 
-
 
32
// #1645: Alert the user if opening FCKeditor in FF3 from local filesystem
-
 
33
// without security.fileuri.strict_origin_policy disabled.
-
 
34
if ( document.location.protocol == 'file:' )
-
 
35
{
-
 
36
	try
-
 
37
	{
-
 
38
		window.parent.document.domain ;
-
 
39
	}
-
 
40
	catch ( e )
-
 
41
	{
-
 
42
		window.addEventListener( 'load', function()
-
 
43
			{
-
 
44
				document.body.innerHTML = '\
-
 
45
					<div style="border: 1px red solid; font-family: arial; font-size: 12px; color: red; padding:10px;">\
-
 
46
						<p>\
-
 
47
							<b>Your browser security settings don\'t allow FCKeditor to be opened from\
-
 
48
							the local filesystem.<\/b>\
-
 
49
						<\/p>\
-
 
50
						<p>\
-
 
51
							Please open the <b>about:config<\/b> page and disable the\
-
 
52
							&quot;security.fileuri.strict_origin_policy&quot; option; then load this page again.\
-
 
53
						<\/p>\
-
 
54
						<p>\
-
 
55
							Check our <a href="http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/FAQ#ff3perms">FAQ<\/a>\
-
 
56
							for more information.\
-
 
57
						<\/p>\
-
 
58
					<\/div>' ;
-
 
59
			}, false ) ;
-
 
60
	}
-
 
61
}
-
 
62
 
-
 
63
// Save a reference to the default domain.
-
 
64
var FCK_ORIGINAL_DOMAIN ;
-
 
65
 
-
 
66
// Automatically detect the correct document.domain (#123).
-
 
67
(function()
-
 
68
{
-
 
69
	var d = FCK_ORIGINAL_DOMAIN = document.domain ;
-
 
70
 
-
 
71
	while ( true )
-
 
72
	{
-
 
73
		// Test if we can access a parent property.
-
 
74
		try
-
 
75
		{
-
 
76
			var test = window.parent.document.domain ;
-
 
77
			break ;
-
 
78
		}
-
 
79
		catch( e ) {}
-
 
80
 
-
 
81
		// Remove a domain part: www.mytest.example.com => mytest.example.com => example.com ...
-
 
82
		d = d.replace( /.*?(?:\.|$)/, '' ) ;
-
 
83
 
-
 
84
		if ( d.length == 0 )
-
 
85
			break ;		// It was not able to detect the domain.
-
 
86
 
-
 
87
		try
-
 
88
		{
-
 
89
			document.domain = d ;
-
 
90
		}
-
 
91
		catch (e)
-
 
92
		{
-
 
93
			break ;
-
 
94
		}
-
 
95
	}
-
 
96
})() ;
-
 
97
 
-
 
98
// Save a reference to the detected runtime domain.
-
 
99
var FCK_RUNTIME_DOMAIN = document.domain ;
-
 
100
 
-
 
101
var FCK_IS_CUSTOM_DOMAIN = ( FCK_ORIGINAL_DOMAIN != FCK_RUNTIME_DOMAIN ) ;
27
 
102
 
28
// Instead of loading scripts and CSSs using inline tags, all scripts are
103
// Instead of loading scripts and CSSs using inline tags, all scripts are
29
// loaded by code. In this way we can guarantee the correct processing order,
104
// loaded by code. In this way we can guarantee the correct processing order,
30
// otherwise external scripts and inline scripts could be executed in an
105
// otherwise external scripts and inline scripts could be executed in an
Line 31... Line 106...
31
// unwanted order (IE).
106
// unwanted order (IE).
32
 
107
 
33
function LoadScript( url )
108
function LoadScript( url )
34
{
-
 
35
	document.write( '<script type="text/javascript" src="' + url + '" onerror="alert(\'Error loading \' + this.src);"><\/script>' ) ;
-
 
36
}
-
 
37
 
-
 
38
function LoadCss( url )
-
 
39
{
109
{
Line 40... Line 110...
40
	document.write( '<link href="' + url + '" type="text/css" rel="stylesheet" onerror="alert(\'Error loading \' + this.src);" />' ) ;
110
	document.write( '<scr' + 'ipt type="text/javascript" src="' + url + '"><\/scr' + 'ipt>' ) ;
41
}
111
}
Line 42... Line 112...
42
 
112
 
Line 43... Line 113...
43
// Main editor scripts.
113
// Main editor scripts.
44
var sSuffix = /msie/.test( navigator.userAgent.toLowerCase() ) ? 'ie' : 'gecko' ;
114
var sSuffix = ( /*@cc_on!@*/false ) ? 'ie' : 'gecko' ;
Line 45... Line 115...
45
 
115
 
46
LoadScript( 'js/fckeditorcode_' + sSuffix + '.js' ) ;
116
LoadScript( 'js/fckeditorcode_' + sSuffix + '.js' ) ;
Line 47... Line 117...
47
 
117
 
-
 
118
// Base configuration file.
-
 
119
LoadScript( '../fckconfig.js' ) ;
-
 
120
 
48
// Base configuration file.
121
	</script>
49
LoadScript( '../fckconfig.js' ) ;
122
	<script type="text/javascript">
-
 
123
 
-
 
124
// Adobe AIR compatibility file.
-
 
125
if ( FCKBrowserInfo.IsAIR )
-
 
126
	LoadScript( 'js/fckadobeair.js' ) ;
-
 
127
 
-
 
128
if ( FCKBrowserInfo.IsIE )
-
 
129
{
-
 
130
	// Remove IE mouse flickering.
-
 
131
	try
-
 
132
	{
-
 
133
		document.execCommand( 'BackgroundImageCache', false, true ) ;
-
 
134
	}
50
 
135
	catch (e)
51
	</script>
136
	{
52
	<script type="text/javascript">
137
		// We have been reported about loading problems caused by the above
53
 
138
		// line. For safety, let's just ignore errors.
Line -... Line 139...
-
 
139
	}
-
 
140
 
-
 
141
	// Create the default cleanup object used by the editor.
-
 
142
	FCK.IECleanup = new FCKIECleanup( window ) ;
-
 
143
	FCK.IECleanup.AddItem( FCKTempBin, FCKTempBin.Reset ) ;
54
// Create the default cleanup object used by the editor.
144
	FCK.IECleanup.AddItem( FCK, FCK_Cleanup ) ;
55
if ( FCKBrowserInfo.IsIE )
145
}
56
{
146
 
Line 57... Line 147...
57
	FCK.IECleanup = new FCKIECleanup( window ) ;
147
// The first function to be called on selection change must the the styles
Line 73... Line 163...
73
// Load configurations defined at page level.
163
// Load configurations defined at page level.
74
FCKConfig_LoadPageConfig() ;
164
FCKConfig_LoadPageConfig() ;
Line 75... Line 165...
75
 
165
 
Line -... Line 166...
-
 
166
FCKConfig_PreProcess() ;
-
 
167
 
-
 
168
// Load the full debug script.
-
 
169
if ( FCKConfig.Debug )
-
 
170
	LoadScript( '_source/internals/fckdebug.js' ) ;
-
 
171
 
-
 
172
	</script>
-
 
173
	<script type="text/javascript">
-
 
174
 
-
 
175
// CSS minified by http://iceyboard.no-ip.org/projects/css_compressor (see _dev/css_compression.txt).
-
 
176
var FCK_InternalCSS			= FCKTools.FixCssUrls( FCKConfig.BasePath + 'css/', 'html{min-height:100%}table.FCK__ShowTableBorders,table.FCK__ShowTableBorders td,table.FCK__ShowTableBorders th{border:#d3d3d3 1px solid}form{border:1px dotted #F00;padding:2px}.FCK__Flash{border:#a9a9a9 1px solid;background-position:center center;background-image:url(images/fck_flashlogo.gif);background-repeat:no-repeat;width:80px;height:80px}.FCK__UnknownObject{border:#a9a9a9 1px solid;background-position:center center;background-image:url(images/fck_plugin.gif);background-repeat:no-repeat;width:80px;height:80px}.FCK__Anchor{border:1px dotted #00F;background-position:center center;background-image:url(images/fck_anchor.gif);background-repeat:no-repeat;width:16px;height:15px;vertical-align:middle}.FCK__AnchorC{border:1px dotted #00F;background-position:1px center;background-image:url(images/fck_anchor.gif);background-repeat:no-repeat;padding-left:18px}a[name]{border:1px dotted #00F;background-position:0 center;background-image:url(images/fck_anchor.gif);background-repeat:no-repeat;padding-left:18px}.FCK__PageBreak{background-position:center center;background-image:url(images/fck_pagebreak.gif);background-repeat:no-repeat;clear:both;display:block;float:none;width:100%;border-top:#999 1px dotted;border-bottom:#999 1px dotted;border-right:0;border-left:0;height:5px}.FCK__InputHidden{width:19px;height:18px;background-image:url(images/fck_hiddenfield.gif);background-repeat:no-repeat;vertical-align:text-bottom;background-position:center center}.FCK__ShowBlocks p,.FCK__ShowBlocks div,.FCK__ShowBlocks pre,.FCK__ShowBlocks address,.FCK__ShowBlocks blockquote,.FCK__ShowBlocks h1,.FCK__ShowBlocks h2,.FCK__ShowBlocks h3,.FCK__ShowBlocks h4,.FCK__ShowBlocks h5,.FCK__ShowBlocks h6{background-repeat:no-repeat;border:1px dotted gray;padding-top:8px;padding-left:8px}.FCK__ShowBlocks p{background-image:url(images/block_p.png)}.FCK__ShowBlocks div{background-image:url(images/block_div.png)}.FCK__ShowBlocks pre{background-image:url(images/block_pre.png)}.FCK__ShowBlocks address{background-image:url(images/block_address.png)}.FCK__ShowBlocks blockquote{background-image:url(images/block_blockquote.png)}.FCK__ShowBlocks h1{background-image:url(images/block_h1.png)}.FCK__ShowBlocks h2{background-image:url(images/block_h2.png)}.FCK__ShowBlocks h3{background-image:url(images/block_h3.png)}.FCK__ShowBlocks h4{background-image:url(images/block_h4.png)}.FCK__ShowBlocks h5{background-image:url(images/block_h5.png)}.FCK__ShowBlocks h6{background-image:url(images/block_h6.png)}' ) ;
-
 
177
var FCK_ShowTableBordersCSS	= FCKTools.FixCssUrls( FCKConfig.BasePath + 'css/', 'table:not([border]),table:not([border]) > tr > td,table:not([border]) > tr > th,table:not([border]) > tbody > tr > td,table:not([border]) > tbody > tr > th,table:not([border]) > thead > tr > td,table:not([border]) > thead > tr > th,table:not([border]) > tfoot > tr > td,table:not([border]) > tfoot > tr > th,table[border=\"0\"],table[border=\"0\"] > tr > td,table[border=\"0\"] > tr > th,table[border=\"0\"] > tbody > tr > td,table[border=\"0\"] > tbody > tr > th,table[border=\"0\"] > thead > tr > td,table[border=\"0\"] > thead > tr > th,table[border=\"0\"] > tfoot > tr > td,table[border=\"0\"] > tfoot > tr > th{border:#d3d3d3 1px dotted}' ) ;
-
 
178
 
-
 
179
// Popup the debug window if debug mode is set to true. It guarantees that the
-
 
180
// first debug message will not be lost.
-
 
181
if ( FCKConfig.Debug )
76
FCKConfig_PreProcess() ;
182
	FCKDebug._GetWindow() ;
77
 
183
 
Line 78... Line 184...
78
// Load the active skin CSS.
184
// Load the active skin CSS.
79
LoadCss( FCKConfig.SkinPath + 'fck_editor.css' ) ;
185
document.write( FCKTools.GetStyleHtml( FCKConfig.SkinEditorCSS ) ) ;
80
 
186
 
Line 90... Line 196...
90
 
196
 
Line 91... Line 197...
91
FCKPlugins.Load() ;
197
FCKPlugins.Load() ;
92
 
198
 
93
	</script>
199
	</script>
94
	<script type="text/javascript">
200
	<script type="text/javascript">
95
	
201
 
Line 96... Line -...
96
// Set the editor interface direction.
-
 
97
window.document.dir = FCKLang.Dir ;
-
 
98
 
-
 
99
// Activate pasting operations.
-
 
100
if ( FCKConfig.ForcePasteAsPlainText || FCKConfig.AutoDetectPasteFromWord )
202
// Set the editor interface direction.
101
	FCK.Events.AttachEvent( "OnPaste", FCK.Paste ) ;
203
window.document.dir = FCKLang.Dir ;
Line 102... Line 204...
102
 
204
 
103
	</script>
205
	</script>
Line 119... Line 221...
119
}
221
}
Line 120... Line 222...
120
 
222
 
121
function LoadToolbar()
223
function LoadToolbar()
122
{
224
{
123
	var oToolbarSet = FCK.ToolbarSet = FCKToolbarSet_Create() ;
225
	var oToolbarSet = FCK.ToolbarSet = FCKToolbarSet_Create() ;
124
	
226
 
125
	if ( oToolbarSet.IsLoaded )
227
	if ( oToolbarSet.IsLoaded )
126
		StartEditor() ;
228
		StartEditor() ;
127
	else
229
	else
128
	{
230
	{
Line 149... Line 251...
149
	if ( newStatus == FCK_STATUS_ACTIVE )
251
	if ( newStatus == FCK_STATUS_ACTIVE )
150
	{
252
	{
151
		if ( FCKBrowserInfo.IsGecko )
253
		if ( FCKBrowserInfo.IsGecko )
152
			FCKTools.RunFunction( window.onresize ) ;
254
			FCKTools.RunFunction( window.onresize ) ;
Line -... Line 255...
-
 
255
 
-
 
256
		if ( !FCKConfig.PreventSubmitHandler )
-
 
257
			_AttachFormSubmitToAPI() ;
153
 
258
 
Line 154... Line 259...
154
		FCK.SetStatus( FCK_STATUS_COMPLETE ) ;
259
		FCK.SetStatus( FCK_STATUS_COMPLETE ) ;
155
 
260
 
156
		// Call the special "FCKeditor_OnComplete" function that should be present in 
261
		// Call the special "FCKeditor_OnComplete" function that should be present in
157
		// the HTML page where the editor is located.
262
		// the HTML page where the editor is located.
158
		if ( typeof( window.parent.FCKeditor_OnComplete ) == 'function' )
263
		if ( typeof( window.parent.FCKeditor_OnComplete ) == 'function' )
159
			window.parent.FCKeditor_OnComplete( FCK ) ;	
264
			window.parent.FCKeditor_OnComplete( FCK ) ;
Line 160... Line 265...
160
	}
265
	}
161
}
266
}
162
 
267
 
163
// Gecko browsers doens't calculate well that IFRAME size so we must
268
// Gecko browsers doesn't calculate well the IFRAME size so we must
164
// recalculate it every time the window size changes.
269
// recalculate it every time the window size changes.
165
if ( FCKBrowserInfo.IsGecko )
270
if ( FCKBrowserInfo.IsGecko && !FCKBrowserInfo.IsOpera )
-
 
271
{
166
{
272
	window.onresize = function( e )
-
 
273
	{
-
 
274
		// Running in Chrome makes the window receive the event including subframes.
167
	function Window_OnResize()
275
		// we care only about this window. Ticket #1642.
Line 168... Line 276...
168
	{
276
		// #2002: The originalTarget from the event can be the current document, the window, or the editing area.
Line 169... Line 277...
169
		if ( FCKBrowserInfo.IsOpera )
277
		if ( e && e.originalTarget !== document && e.originalTarget !== window && (!e.originalTarget.ownerDocument || e.originalTarget.ownerDocument != document ))
170
			return ;
278
			return ;
171
 
279
 
172
		var oCell = document.getElementById( 'xEditingArea' ) ;
280
		var oCell = document.getElementById( 'xEditingArea' ) ;
173
 
281
 
174
		var eInnerElement ;
282
		var eInnerElement = oCell.firstChild ;
175
		if ( eInnerElement = oCell.firstChild )
283
		if ( eInnerElement )
176
		{
-
 
177
			eInnerElement.style.height = 0 ;
284
		{
Line 178... Line 285...
178
			eInnerElement.style.height = oCell.scrollHeight - 2 ;
285
			eInnerElement.style.height = '0px' ;
179
		}
286
			eInnerElement.style.height = ( oCell.scrollHeight - 2 ) + 'px' ;
180
	}
287
		}
Line 200... Line 307...
200
						<td class="TB_SideBorder" style="width: 1px"></td>
307
						<td class="TB_SideBorder" style="width: 1px"></td>
201
					</tr>
308
					</tr>
202
				</table>
309
				</table>
203
			</td>
310
			</td>
204
		</tr>
311
		</tr>
205
		<tr style="height: 100%">
312
		<tr>
206
			<td id="xEditingArea" valign="top"></td>
313
			<td id="xEditingArea" valign="top" style="height: 100%"></td>
207
		</tr>
314
		</tr>
208
	</table>
315
	</table>
209
</body>
316
</body>
210
</html>
317
</html>