Project

General

Profile

« Previous | Next » 

Revision 1161

Added by Dietmar over 14 years ago

new update FCKeditor to Version 2.6.5 Modulversion 2.9.1

View differences:

fck_table.html
155 155
	SetAttribute( table, 'cellSpacing'	, GetE('txtCellSpacing').value ) ;
156 156
	SetAttribute( table, 'summary'		, GetE('txtSummary').value ) ;
157 157

  
158
	var eCaption = oEditor.FCKDomTools.GetFirstChild( table, 'CAPTION' ) ;
159

  
160
	if ( document.getElementById('txtCaption').value != '')
161
	{
162
		if ( !eCaption )
163
		{
164
			eCaption = oDoc.createElement( 'CAPTION' ) ;
165
			table.insertBefore( eCaption, table.firstChild ) ;
166
		}
167

  
168
		eCaption.innerHTML = document.getElementById('txtCaption').value ;
169
	}
170
	else if ( bExists && eCaption )
171
	{
172
		// TODO: It causes an IE internal error if using removeChild or
173
		// table.deleteCaption() (see #505).
174
		if ( oEditor.FCKBrowserInfo.IsIE )
175
			eCaption.innerHTML = '' ;
176
		else
177
			eCaption.parentNode.removeChild( eCaption ) ;
178
	}
179

  
180 158
	var headers = GetE('selHeaders').value ;
181 159
	if ( bExists )
182 160
	{
......
307 285
		oEditor.FCK.InsertElement( table ) ;
308 286
	}
309 287

  
288
	var eCaption = oEditor.FCKDomTools.GetFirstChild( table, 'CAPTION' ) ;
289

  
290
	if ( eCaption && !oEditor.FCKBrowserInfo.IsIE )
291
		eCaption.parentNode.removeChild( eCaption ) ;
292

  
293
	if ( document.getElementById('txtCaption').value != '' )
294
	{
295
		if ( !eCaption || !oEditor.FCKBrowserInfo.IsIE )
296
		{
297
			eCaption = oDoc.createElement( 'CAPTION' ) ;
298
			table.insertBefore( eCaption, table.firstChild ) ;
299
		}
300

  
301
		eCaption.innerHTML = document.getElementById('txtCaption').value ;
302
	}
303
	else if ( bExists && eCaption )
304
	{
305
		// TODO: It causes an IE internal error if using removeChild or
306
		// table.deleteCaption() (see #505).
307
		if ( oEditor.FCKBrowserInfo.IsIE )
308
			eCaption.innerHTML = '' ;
309
	}
310

  
310 311
	return true ;
311 312
}
312 313

  

Also available in: Unified diff