PDA

View Full Version : Autoload of a form panel



marco76
4 Apr 2008, 12:14 AM
Hi
I have made a modify to the MainPanel class of the FeedReader example.
My modify is simple.I would add to the Tab Panel a form panel with autoload of the firld from a PHP script.
My code is




this.form=new Ext.FormPanel({
url:'url.php',
method:'POST',
title:'Prova',
labelWidth: 75,
defaultType: 'textfield',
id:'form-DOC',
border:false,
items: [],
autoLoad:{url: 'form.php',
renderer:
{
render: function(el, response, updater, callback)
{ this.form.add.apply(this.form,[].concat(eval(response.responseText) ) );
this.form.doLayout();
this.doLayout();
if(callback)callback();
}.createDelegate(this)
}
}
});

My problem is that I can see the new panel but this panel is empty.
What is the error?
Many Thanks