2
* FCKeditor - The text editor for internet
3
* Copyright (C) 2003-2005 Frederico Caldeira Knabben
5
* Licensed under the terms of the GNU Lesser General Public License:
6
* http://www.opensource.org/licenses/lgpl-license.php
8
* For further information visit:
9
* http://www.fckeditor.net/
11
* "Support Open Source software. What about a donation today?"
14
* Creation and initialization of the "FCK" object. This is the main object
15
* that represents an editor instance.
18
* Frederico Caldeira Knabben (fredck@fckeditor.net)
21
// FCK represents the active editor instance
22
var FCK = new Object() ;
23
FCK.Name = FCKURLParams[ 'InstanceName' ] ;
25
FCK.Status = FCK_STATUS_NOTLOADED ;
26
FCK.EditMode = FCK_EDITMODE_WYSIWYG ;
28
FCK.LoadLinkedFile = function()
30
// There is a bug on IE... getElementById returns any META tag that has the
31
// name set to the ID you are looking for. So the best way in to get the array
32
// by names and look for the correct one.
33
// As ASP.Net generates a ID that is different from the Name, we must also
34
// look for the field based on the ID (the first one is the ID).
36
var oDocument = window.parent.document ;
38
var eLinkedField = oDocument.getElementById( FCK.Name ) ;
39
var colElementsByName = oDocument.getElementsByName( FCK.Name ) ;
42
while ( eLinkedField || i == 0 )
44
if ( eLinkedField && ( eLinkedField.tagName == 'INPUT' || eLinkedField.tagName == 'TEXTAREA' ) )
46
FCK.LinkedField = eLinkedField ;
49
eLinkedField = colElementsByName[i++] ;
52
FCK.LoadLinkedFile() ;
54
var FCKTempBin = new Object() ;
55
FCKTempBin.Elements = new Array() ;
57
FCKTempBin.AddElement = function( element )
59
var iIndex = FCKTempBin.Elements.length ;
60
FCKTempBin.Elements[ iIndex ] = element ;
64
FCKTempBin.RemoveElement = function( index )
66
var e = FCKTempBin.Elements[ index ] ;
67
FCKTempBin.Elements[ index ] = null ;
71
FCKTempBin.Reset = function()
74
while ( i < FCKTempBin.Elements.length )
75
FCKTempBin.Elements[ i++ ] == null ;
76
FCKTempBin.Elements.length = 0 ;
b'\\ No newline at end of file'