pclacerda
14 Nov 2007, 1:11 PM
I have an HTML form inside a popup (Ext.LayoutDialog) I need the user submits the form and the response appears inside the popup, however what happens is that when the user submits the form the response replaces the whole page....
Here is the popup code (the form is in popup-page.html):
dialog = new Ext.LayoutDialog("popup-dlg", {
modal:true,
width:626,
height:453,
shadow:true,
minWidth:600,
minHeight:443,
proxyDrag: true,
center: {
autoScroll:true,
tabPosition: 'top',
closeOnTab: true,
alwaysShowTabs: false
}
});
dialog.addKeyListener(27, dialog.hide, dialog);
btnConfirmar = dialog.addButton('Confirmar', dialog.hide, dialog);
dialog.addButton('Cancelar', dialog.hide, dialog);
btnConfirmar.on('click',confirmar);
var layout = dialog.getLayout();
layout.beginUpdate();
conteudo = new Ext.ContentPanel('center', {title: ''});
layout.add('center', conteudo);
conteudo.load({
url: './popup-page.html',
discardUrl: false,
nocache: false,
text: "Carregando...",
timeout: 30,
scripts: false
});
// generate some other tabs
layout.endUpdate();
dialog.show(Ext.getDom());
Here is the popup code (the form is in popup-page.html):
dialog = new Ext.LayoutDialog("popup-dlg", {
modal:true,
width:626,
height:453,
shadow:true,
minWidth:600,
minHeight:443,
proxyDrag: true,
center: {
autoScroll:true,
tabPosition: 'top',
closeOnTab: true,
alwaysShowTabs: false
}
});
dialog.addKeyListener(27, dialog.hide, dialog);
btnConfirmar = dialog.addButton('Confirmar', dialog.hide, dialog);
dialog.addButton('Cancelar', dialog.hide, dialog);
btnConfirmar.on('click',confirmar);
var layout = dialog.getLayout();
layout.beginUpdate();
conteudo = new Ext.ContentPanel('center', {title: ''});
layout.add('center', conteudo);
conteudo.load({
url: './popup-page.html',
discardUrl: false,
nocache: false,
text: "Carregando...",
timeout: 30,
scripts: false
});
// generate some other tabs
layout.endUpdate();
dialog.show(Ext.getDom());