OK, simple question. I have this custom form:
function TestForm() {
$fields = new FieldSet(
new TextField('NumA', 'Number A'),
new TextField('NumB', 'Number B')
);
$actions = new FieldSet(
new FormAction('doSubmitNumbers', 'Calculate')
);
$form = new Form(
$this,
'Form',
$fields,
$actions
);
return $form;
}
The only thing I want the function doSubmitNumbers to do, is to perform some calculation (say, add NumA and NumB) and show the result on the page when it redirects back. I know how I would use doSubmitNumbers to save to the database, but I actually don't want to save to the database, just show the result of the calculation... How would I go forward?
Thanks!
Edit: wording.