PDA

View Full Version : [Update]Ext & FCKeditor Integration



hb562100
14 Nov 2008, 6:00 PM
Hi all guys,

thanks to reply my post :">, so give me power to strong my code.This version solve mschwartz's problem, that my wrong.

e...,added event 'editorRender' , fix when call ownCt.doLayout().

Other, thanks mschwartz,Zig...

@Support ext's layout.
You can use ext's layout to fit the container of editor(as 'fit') ,instead of set 'Height' and 'Width'.

@Support change toolbarset dynamically.
Use setToolbarSet to do this. Code maybe like : Ext.getCmp(editor.Name).setToolbarSet('Basic');

@Support events : resize , toolSetChanged , editorRender and Ext.Component's events.


@Note

Property id doesn't work now , it will be set the same as 'Name',so you wanna to get this component ,use Ext.getCmp(Name);
Property Name , MUST be set.
The FCKeditor's direct Properties : Width,Height,ToolbarSet,Value,BasePath,CheckBrowser
The FCKeditor's Config Properties( the same as fckConfig ): refer to http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options




update 09-15-2009
BasePath is work now ,thanks 666ragez666 (http://www.extjs.com/forum/member.php?u=60841)

/**
* Class FCKeditor
* Ext & FCKeditor Integration
*
* @author <a href="mailto:hb562100@163.com">hb562100</a>
* @version 2008-12-11
* @Ext forum thread <a href=http://extjs.com/forum/showthread.php?p=263517>http://extjs.com/forum/showthread.php?p=263517</a>
*
* @extend Ext.Component
*/


/**
* @Support ext's layout.
* You can use ext's layout to fit the container of editor(as 'fit') ,instead of set 'Height' and 'Width'.
*
* @Support change toolbarset dynamically.
* Use <b>setToolbarSet</b> to do this. Code maybe like : <i>Ext.getCmp(editor.Name).setToolbarSet('Basic');</i>
*
* @Support events : resize , toolSetChanged , editorRender and Ext.Component's events.
*
* <ul>
* <li>Property id doesn't work now , it will be set the same as 'Name',so you wanna to get this component ,use Ext.getCmp(Name); </li>
* <li>Property Name , MUST be set.</li>
* <li>The FCKeditor's direct Properties : Width,Height,ToolbarSet,Value,BasePath,CheckBrowser</li>
* <li>The FCKeditor's Config Properties( the same as fckConfig ): refer to <a href="http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options">http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options</a></li>
* </ul>
*/

Ext.ux.FCKeditor = Ext.extend(Ext.Component,
{
constructor : function( conf ){
if(!conf.editor){
conf.editor
= new FCKeditor(
conf.Name
,conf.Width
,conf.Height
,conf.ToolbarSet
,conf.Value
);

if(conf.BasePath){
conf.editor.BasePath = conf.BasePath;
}
}

Ext.apply(
conf , conf.editor
);

Ext.apply(conf.Config,
conf.fckConfig
);

//define/modify ext's component id
conf.id = conf.Name;

Ext.ux.FCKeditor.superclass.constructor.call(this, conf);

this.addEvents(
[
/**
* @Event Function(editor)
* Fires after the size of the editor is changed.
*/
'resize',

/**
* @Event Function(editor , toolset)
* Fires after the toolset of the editor is changed.
*/
'toolSetChanged',


/**
* @Event Function(editor)
* Fires after the editor is rendered.
*/
'editorRender'

]
);
},
//private
onRender: function(ct, position){
if(!this.tpl){
this.tpl = new Ext.XTemplate(
'<div class="x-window-mc">',this.CreateHtml(),'</div>'
);
}
if(position){
this.el = this.tpl.insertBefore(position,this ,true);
}else{
this.el = this.tpl.append(ct,this ,true);
}
},
/**
* Get inner FCKeditor instance.
*/
getInnerEditor : function(){
/**
* Use FCKeditorAPI.GetInstance() maybe cause null erorr,
* when call 'Create' or 'ReplaceTextarea' twice more.
*/

/*if(FCKeditorAPI)
return FCKeditorAPI.GetInstance(this.Name);*/

/**
* Ext.ux.FCKeditorMgr can automatic register FCKeditor when the editor was rendered.
*/
return Ext.ux.FCKeditorMgr.get(this.Name);
},

/**
* This method can fire 'toolSetChanged' event.
* @param {String} set , the set of toolbar
*/
setToolbarSet : function(set){
var inner = this.getInnerEditor();
if(inner)
this.Value = inner.GetData();

this.ToolbarSet = set;
this.el.dom.innerHTML=this.CreateHtml();

this.fireEvent( 'toolSetChanged' , this, set);
},

/**
* Set this size of editor.
*
* @param {Object} size ,{ width : ..., height: ...}
* @param {Boolean/Object} , use animate
*/
setSize : function(size ,animate){
if(!this. rendered)
return ;
var domEl = this.getEditorFrame();

if(domEl)
domEl.setSize(size.width ,size.height,animate);

//var size = this.getSize();

this.Width = size.width;
this.Height = size.height;

this.fireEvent( 'resize' , this);
},
/**
* Get this size of editor.
*
* return {Object} {width: {Number} , height:{Nnmber}}
*/
getSize : function(){
return this.el.getSize();
},
/**
* Set this height of editor.
* @param {String} h ,height
*/
setHeight : function(h){
if(!this. rendered)
return ;

var domEl = this.getEditorFrame();

if(domEl)
domEl.setHeight(h);

this.Height = this.getHeight();

this.fireEvent( 'resize' , this);
},
/**
* Get this height of editor.
* @return {Nunber}
*/
getHeight : function(){
return this.el.getHeight();
},
/**
* Set this width of editor.
* @param {String} w ,width
*/
setWidth : function(w){
if(!this. rendered)
return ;

var domEl = this.getEditorFrame();

if(domEl)
domEl.setWidth(w);

this.Width = this.el.getWidth();

this.fireEvent( 'resize' , this);
},
/**
* Get this width of editor.
* @return {Nunber}
*/
getWidth : function(){
return this.el.getWidth();
},

/**
* The value of editor's Getter & Setter.
*/
setValue : function(html){
this.getInnerEditor().SetData(html);
},
getValue : function(){
return this.getInnerEditor().GetData();
},

//private
getEditorFrame : function(){
if(!this. rendered)
return null;

var dom =
Ext.get(
Ext.query("iframe",
this.el.dom
)[0]
);
return Ext.get(dom);
},
/**
* override
*/
destroy: function(){
Ext.ux.FCKeditorMgr.remove(this.Name);
Ext.ux.FCKeditor.superclass.destroy.call(this);
}
}
);

Ext.ux.FCKeditorMgr = (function(){
var collections = new Object();
return {
register : function (name , o){
collections[name] = o;
var editor = Ext.getCmp(name);

if(editor.ownerCt){
editor.ownerCt.doLayout();
}
editor.fireEvent('editorRender',editor);
},
remove : function(name){
delete collections[name];
},
get :function (name){
return collections[name];
}
};
})();

FCKeditor_OnComplete =
typeof FCKeditor_OnComplete == 'function'?
FCKeditor_OnComplete.createSequence(
function( instance ){
Ext.ux.FCKeditorMgr.register(instance.Name , instance);
},FCKeditor_OnComplete):
function( instance ){
Ext.ux.FCKeditorMgr.register(instance.Name , instance);
};

Ext.reg('fckeditor' , Ext.ux.FCKeditor);

DEMO CODE

Ext.onReady(function(){
new Ext.Panel({
title : 'Demo For Ext & FCKeditor Integration',
width : 600,
height : 400,
id: 'panel',
layout: 'fit', // fckeditor support Ext's layout.
renderTo: Ext.getBody(),
monitorResize : true,
items : [
{
/**
* Ext's Config Options
*/
xtype : 'fckeditor',

/**
* FCKeditor's Config Options
*/
Name : 'editor',
ToolbarSet : 'Basic',
BasePath: '/fckeditor/', // If your fckeditor set up the root path,or fix it.
Value :'Welcome to China!!!',

/**
* 'fckConfig' will apply to fckeditor.Config
*/
fckConfig : {
//CustomConfigurationsPath: 'myconfig.js'
}
}
]
});

var editor = Ext.getCmp('editor');
/**
* Set Event Listener
*/
editor.on('toolSetChanged',function(edtr,set){
Ext.get('note').update('The toolset of the editor is '+ set);
});

});

image for demo
http://mylib.duxiu.com/userfile/6020391/2008-11-15/1226713565455.jpg

mschwartz
3 Dec 2008, 3:38 PM
Mostly working as you posted it.

I have fckeditor not in the root. I had to make some slight changes.



pwp.editorid = 0;
pwp.Editor = function() {
pwp.editorid++;
FCKeditor.BasePath = '/frameworks/fckeditor/';
var dialog = new Ext.Window({
title: 'Editor'
,width: 700
,height: 400
// ,modal: true
,layout: 'fit'
,items: new Ext.ux.FCKeditor({
Name: 'editor' + pwp.editorid
,ToolbarSet: 'Default'
,BasePath: '/frameworks/fckeditor/'
,fckConfig: {BasePath: '/frameworks/fckeditor/editor/'}
})
});
dialog.show();
dialog.center();
}


Note: FCKEditor.BasePath has to be set!
Note: fckConfig.BasePath must be different or the dialogs do not work.

The only issue I see now is that I can open two windows fine by calling the above function, both editors appear nicely (Name: must be unique!). However, only the first window is 700px wide, all others open maybe 500 wide.

zig999
9 Dec 2008, 2:46 AM
I was not able to test it yet. I

nanich
11 Dec 2008, 6:06 PM
Really a very good plugins. I made my work so simpler. Thank you very much.

pablitobs
15 Dec 2008, 6:16 PM
Hi all guys,
thanks to reply my post :">, so give me power to strong my code.This version solve mschwartz's problem, that my wrong.

e...,added event 'editorRender' , fix when call ownCt.doLayout().

Other, thanks mschwartz,Zig...

@Support ext's layout.
You can use ext's layout to fit the container of editor(as 'fit') ,instead of set 'Height' and 'Width'.

@Support change toolbarset dynamically.
Use setToolbarSet to do this. Code maybe like : Ext.getCmp(editor.Name).setToolbarSet('Basic');

@Support events : resize , toolSetChanged , editorRender and Ext.Component's events.


@Note

Property id doesn't work now , it will be set the same as 'Name',so you wanna to get this component ,use Ext.getCmp(Name);
Property Name , MUST be set.
The FCKeditor's direct Properties : Width,Height,ToolbarSet,Value,BasePath,CheckBrowser
The FCKeditor's Config Properties( the same as fckConfig ): refer to http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options


/**
* Class FCKeditor
* Ext & FCKeditor Integration
*
* @author <a href="mailto:hb562100@163.com">hb562100</a>
* @version 2008-12-11
*
* @extend Ext.Component
*/


/**
* @Support ext's layout.
* You can use ext's layout to fit the container of editor(as 'fit') ,instead of set 'Height' and 'Width'.
*
* @Support change toolbarset dynamically.
* Use <b>setToolbarSet</b> to do this. Code maybe like : <i>Ext.getCmp(editor.Name).setToolbarSet('Basic');</i>
*
* @Support events : resize , toolSetChanged , editorRender and Ext.Component's events.
*
* <ul>
* <li>Property id doesn't work now , it will be set the same as 'Name',so you wanna to get this component ,use Ext.getCmp(Name); </li>
* <li>Property Name , MUST be set.</li>
* <li>The FCKeditor's direct Properties : Width,Height,ToolbarSet,Value,BasePath,CheckBrowser</li>
* <li>The FCKeditor's Config Properties( the same as fckConfig ): refer to <a href="http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options">http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options</a></li>
* </ul>
*/

Ext.ux.FCKeditor = Ext.extend(Ext.Component,
{
constructor : function( conf ){
if(!conf.editor){
conf.editor
= new FCKeditor(
conf.Name
,conf.Width
,conf.Height
,conf.ToolbarSet
,conf.Value
);
}

Ext.apply(
conf , conf.editor
);

Ext.apply(conf.Config,
conf.fckConfig
);

//define/modify ext's component id
conf.id = conf.Name;

Ext.ux.FCKeditor.superclass.constructor.call(this, conf);

this.addEvents(
[
/**
* @Event Function(editor)
* Fires after the size of the editor is changed.
*/
'resize',

/**
* @Event Function(editor , toolset)
* Fires after the toolset of the editor is changed.
*/
'toolSetChanged',


/**
* @Event Function(editor)
* Fires after the editor is rendered.
*/
'editorRender'

]
);
},
//private
onRender: function(ct, position){
if(!this.tpl){
this.tpl = new Ext.XTemplate(
'<div class="x-window-mc">',this.CreateHtml(),'</div>'
);
}
if(position){
this.el = this.tpl.insertBefore(position,this ,true);
}else{
this.el = this.tpl.append(ct,this ,true);
}
},
/**
* Get inner FCKeditor instance.
*/
getInnerEditor : function(){
/**
* Use FCKeditorAPI.GetInstance() maybe cause null erorr,
* when call 'Create' or 'ReplaceTextarea' twice more.
*/

/*if(FCKeditorAPI)
return FCKeditorAPI.GetInstance(this.Name);*/

/**
* Ext.ux.FCKeditorMgr can automatic register FCKeditor when the editor was rendered.
*/
return Ext.ux.FCKeditorMgr.get(this.Name);
},

/**
* This method can fire 'toolSetChanged' event.
* @param {String} set , the set of toolbar
*/
setToolbarSet : function(set){
var inner = this.getInnerEditor();
if(inner)
this.Value = inner.GetData();

this.ToolbarSet = set;
this.el.dom.innerHTML=this.CreateHtml();

this.fireEvent( 'toolSetChanged' , this, set);
},

/**
* Set this size of editor.
*
* @param {Object} size ,{ width : ..., height: ...}
* @param {Boolean/Object} , use animate
*/
setSize : function(size ,animate){
if(!this. rendered)
return ;
var domEl = this.getEditorFrame();

if(domEl)
domEl.setSize(size.width ,size.height,animate);

//var size = this.getSize();

this.Width = size.width;
this.Height = size.height;

this.fireEvent( 'resize' , this);
},
/**
* Get this size of editor.
*
* return {Object} {width: {Number} , height:{Nnmber}}
*/
getSize : function(){
return this.el.getSize();
},
/**
* Set this height of editor.
* @param {String} h ,height
*/
setHeight : function(h){
if(!this. rendered)
return ;

var domEl = this.getEditorFrame();

if(domEl)
domEl.setHeight(h);

this.Height = this.getHeight();

this.fireEvent( 'resize' , this);
},
/**
* Get this height of editor.
* @return {Nunber}
*/
getHeight : function(){
return this.el.getHeight();
},
/**
* Set this width of editor.
* @param {String} w ,width
*/
setWidth : function(w){
if(!this. rendered)
return ;

var domEl = this.getEditorFrame();

if(domEl)
domEl.setWidth(w);

this.Width = this.el.getWidth();

this.fireEvent( 'resize' , this);
},
/**
* Get this width of editor.
* @return {Nunber}
*/
getWidth : function(){
return this.el.getWidth();
},

/**
* The value of editor's Getter & Setter.
*/
setValue : function(html){
this.getInnerEditor().SetData(html);
},
getValue : function(){
return this.getInnerEditor().GetData();
},

//private
getEditorFrame : function(){
if(!this. rendered)
return null;

var dom =
Ext.get(
Ext.query("iframe",
this.el.dom
)[0]
);
return Ext.get(dom);
},
/**
* override
*/
destroy: function(){
Ext.ux.FCKeditorMgr.remove(this.Name);
Ext.ux.FCKeditor.superclass.destroy.call(this);
}
}
);

Ext.ux.FCKeditorMgr = (function(){
var collections = new Object();
return {
register : function (name , o){
collections[name] = o;
var editor = Ext.getCmp(name);

if(editor.ownerCt){
editor.ownerCt.doLayout();
}
editor.fireEvent('editorRender',editor);
},
remove : function(name){
delete collections[name];
},
get :function (name){
return collections[name];
}
};
})();

FCKeditor_OnComplete =
typeof FCKeditor_OnComplete == 'function'?
FCKeditor_OnComplete.createSequence(
function( instance ){
Ext.ux.FCKeditorMgr.register(instance.Name , instance);
},FCKeditor_OnComplete):
function( instance ){
Ext.ux.FCKeditorMgr.register(instance.Name , instance);
};

Ext.reg('fckeditor' , Ext.ux.FCKeditor);

DEMO CODE

Ext.onReady(function(){
new Ext.Panel({
title : 'Demo For Ext & FCKeditor Integration',
width : 600,
height : 400,
id: 'panel',
layout: 'fit', // fckeditor support Ext's layout.
renderTo: Ext.getBody(),
monitorResize : true,
items : [
{
/**
* Ext's Config Options
*/
xtype : 'fckeditor',

/**
* FCKeditor's Config Options
*/
Name : 'editor',
ToolbarSet : 'Basic',
BasePath: '/fckeditor/', // If your fckeditor set up the root path,or fix it.
Value :'Welcome to China!!!',

/**
* 'fckConfig' will apply to fckeditor.Config
*/
fckConfig : {
//CustomConfigurationsPath: 'myconfig.js'
}
}
]
});

var editor = Ext.getCmp('editor');
/**
* Set Event Listener
*/
editor.on('toolSetChanged',function(edtr,set){
Ext.get('note').update('The toolset of the editor is '+ set);
});

});

image for demo
http://mylib.duxiu.com/userfile/6020391/2008-11-15/1226713565455.jpg

Hi there I am using your example I did as follow

after include the js file then I have

var fckeditorObject = new Ext.ux.FCKeditor({
Name: 'cableBodyValue'
,ToolbarSet: 'Default_Cable'
,Width: '100%'
,Height: 440
,BasePath: '/fckeditor/'
,fckConfig: {FontSizes: '11px', FontNames: 'Arial'}
});

that works fine.... then I open this window and try to change the fckeditor content by

var templates = new Ext.Window({
width:900
,height:700
,id:'Templates'
,resizable:false
,layout:'fit'
,border:true
,closable:true
,title:'Plantillas'
,items:viewport
,buttons:[{
text: 'Documento en Blanco',
handler: function(){
Ext.getCmp('cableBodyValue').setValue( Ext.getCmp('textBody').html)
}
},{
text: 'Aplicar',
handler: function(){
if (Ext.getCmp('content-panel').layout.activeItem.id != 'start-panel'){
Ext.MessageBox.show({
title:'Salir de SATCON',
msg: 'Esta seguro que desea aplicar esta plantilla?',
buttons: Ext.MessageBox.YESNO,
fn:function(btn, text){
if (btn == 'yes'){
Ext.getCmp('cableType').setValue(Ext.getCmp('type').getValue())
Ext.getCmp('cableDireccion').setValue(Ext.getCmp('dir').getValue())
Ext.getCmp('cableTitulo').setValue(Ext.getCmp('title').getValue())
//Ext.getCmp('cableBodyValue').setValue( '9999'+Ext.getCmp('textBody').html)
templates.hide();
}
},
icon: Ext.MessageBox.QUESTION
})
}
}
},{
text: 'Cerrar',
handler: function(){
templates.hide();
}
}]
});

but I get the error "Object doesn't suppor this property"......

can anybody tell me where is my error, I also try using fckeditorObject.setValue()

hb562100
16 Dec 2008, 5:34 AM
Hi there I am using your example I did as follow

after include the js file then I have

var fckeditorObject = new Ext.ux.FCKeditor({
Name: 'cableBodyValue'
,ToolbarSet: 'Default_Cable'
,Width: '100%'
,Height: 440
,BasePath: '/fckeditor/'
,fckConfig: {FontSizes: '11px', FontNames: 'Arial'}
});

that works fine.... then I open this window and try to change the fckeditor content by

var templates = new Ext.Window({
width:900
,height:700
,id:'Templates'
,resizable:false
,layout:'fit'
,border:true
,closable:true
,title:'Plantillas'
,items:viewport
,buttons:[{
text: 'Documento en Blanco',
handler: function(){
Ext.getCmp('cableBodyValue').setValue( Ext.getCmp('textBody').html)
}
},{
text: 'Aplicar',
handler: function(){
if (Ext.getCmp('content-panel').layout.activeItem.id != 'start-panel'){
Ext.MessageBox.show({
title:'Salir de SATCON',
msg: 'Esta seguro que desea aplicar esta plantilla?',
buttons: Ext.MessageBox.YESNO,
fn:function(btn, text){
if (btn == 'yes'){
Ext.getCmp('cableType').setValue(Ext.getCmp('type').getValue())
Ext.getCmp('cableDireccion').setValue(Ext.getCmp('dir').getValue())
Ext.getCmp('cableTitulo').setValue(Ext.getCmp('title').getValue())
//Ext.getCmp('cableBodyValue').setValue( '9999'+Ext.getCmp('textBody').html)
templates.hide();
}
},
icon: Ext.MessageBox.QUESTION
})
}
}
},{
text: 'Cerrar',
handler: function(){
templates.hide();
}
}]
});

but I get the error "Object doesn't suppor this property"......

can anybody tell me where is my error, I also try using fckeditorObject.setValue()


"Ext.getCmp('cableBodyValue').setValue()" has no error, but make sure your 'cableBodyValue'
editor is exist and finished rendering.

I tested the method of setValue ,which is work fine.

mschwartz
17 Dec 2008, 9:16 AM
Doesn't work as editor for EditGridPanel. You need to figure out which methods you need to implement to make it work :)

mschwartz
9 Jan 2009, 1:24 PM
Does not work as a form field, either.

queej
18 Feb 2009, 1:59 PM
This works pretty well for me, except that it doesn't seem to support the fieldLabel when used in a fieldSet. Do you have any updates to this? I tried zig99's suggested solution, but wasn't able to get it set the value or honor my config settings.

jack sparrow
18 Mar 2009, 9:22 AM
This works pretty well for me, except that it doesn't seem to support the fieldLabel when used in a fieldSet. Do you have any updates to this? I tried zig99's suggested solution, but wasn't able to get it set the value or honor my config settings.

I confirm!!! The script works perfectly, but I notice that following Ext.FormPanel's features has not supported:
1) fieldLabel

Besides, myform.reset() function doesn't work for text written in FCK's textarea

This is my code



Ext.onReady(function(){

var myform = new Ext.FormPanel({
labelAlign: 'top',
url:'mysubmitfile' (http://extjs.com/forum/'mysubmitfile'),
frame:true,
title: 'My Form with FCK & Ext',
bodyStyle:'padding:5px 5px 0',
width: 600,
monitorValid:true,
items: [{
layout:'column',
items:[{
columnWidth:.5,
layout: 'form',
items: [{
xtype:'textfield',
fieldLabel: 'First Name',
name: 'first',
anchor:'95%',
allowBlank:false
}, {
xtype:'textfield',
fieldLabel: 'Company',
name: 'company',
anchor:'95%'
}]
},{
columnWidth:.5,
layout: 'form',
items: [{
xtype:'textfield',
fieldLabel: 'Last Name',
name: 'last',
anchor:'95%'
},{
xtype:'textfield',
fieldLabel: 'Email',
name: 'email',
anchor:'95%'
}]
}]
},{

xtype : 'fckeditor',
fieldLabel:'Biography', // NOT SUPPORTED
Name : 'editor',
ToolbarSet : 'Basic',
BasePath:'/ext-2.2/examples/form/fckeditor/',
fckConfig : {}
}],
buttons:[{
text:'Save',
formBind: true,
// Function that fires when user clicks the button
handler:function(){
myform.getForm().submit({

method:'POST',
waitTitle:'Status',
waitMsg:'...waiting...',

success:function(myform){
Ext.Msg.show({
title:'Status',
msg: 'Well done!!',
buttons: Ext.Msg.OK,
icon: Ext.MessageBox.INFO,
minWidth:'300'
});
myform.reset(); // NOT SUPPORTED
},

failure:function(myform, action){
if(action.failureType == 'server'){
obj = Ext.util.JSON.decode(action.response.responseText);
Ext.Msg.show({
title:'Error',
msg: obj.errors.reason,
buttons: Ext.Msg.OK,
icon: Ext.MessageBox.WARNING,
minWidth:'300'
});
}else{
Ext.Msg.show({
title:'Error',
msg: 'Authentication server is unreachable : ' + action.response.responseText,
buttons: Ext.Msg.OK,
icon: Ext.MessageBox.ERROR,
minWidth:'300'
});
}
myform.reset(); // NOT SUPPORTED
}

});
}
}]
});
myform.render(document.body);

});


Any solution?

Maxime
27 May 2009, 4:10 AM
I tested it with IE8 and several Editor in the same page, it's working fine.
But with FF, i can't change content of field, like a read only form.

666ragez666
5 Jul 2009, 6:27 PM
Just for those who wants to use the BasePath parameter here come a short patch

Thanks to the author of this great extension!


if(!conf.editor){
conf.editor
= new FCKeditor(
conf.Name
,conf.Width
,conf.Height
,conf.ToolbarSet
,conf.Value
);
if(conf.BasePath){
conf.editor.BasePath = conf.BasePath;
}
}