View Full Version : Switch between standform and ajax form

22 Oct 2010, 10:17 AM
Is it possible to switch a FormPanel's standardSubmit and url option on the fly based on say a radio button selection? Switching the standardSubmit and url options back and forth?

22 Oct 2010, 12:30 PM
You can if you initially create your form with standardSumbit:true (otherwise an event handler is attached that stops a standard submit).

22 Oct 2010, 12:33 PM
I am currently creating the form with the standardSubmit: true, however I can't get it to switch back to false when I click the button to submit the form. I couldn't find a set method via the API and doing: this.standardSubmit = false; isn't working either.

22 Oct 2010, 9:31 PM

this.getForm().standardSubmit = false;

22 Oct 2010, 9:38 PM
Cheers Condor, that just made my day!! :D