RE: [PEAR] QFController processing
| From: | Mike Carter | Date: | Fri, 19 Dec 2003 12:00:53 +0000 |
| Subject: | RE: [PEAR] QFController processing | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-9710@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: Alexey Borzov [mailto:borz_off@cs.msu.su]
>
> Mike Carter wrote:
> > Why would this be? I could not find any information in the
> manual for the
> > 'process' action requirements.
>
> The information is written in a forgotten language and is *extremely*
> well hidden.
>
> Quoting
> http://pear.php.net/manual/en/package.html.html-quickform-cont
>roller.faq.php
>
>'process'
>This is the action called by default 'submit' and 'next' (on the last
>page of the wizard only) handlers after successful (i.e. without
>validation errors) form submit. This action doesn't have a default
>handler, you should define the custom one yourself and implement all the
>necessary logic to process the form's values in it.
>
>
>
>I'll probably add a warning about binding it to buttons..
I saw this in the FAQ, but its not exactly helpful! I assume by a warning
you mean it should not be done?
I assumed that if I included the same code as in the 'next' action to the
start of my 'procees' action it should achieve the same thing?
How else do I kick off processing from a form submit button rather than
going on to the next page?
In my process method I added some debug:
var_dump($_POST);echo "<br><br>";
var_dump($page->exportValues());echo "<br><br>";
var_dump($page->controller->exportValues();
The results are strange. It appears the form values are posted to the script
fine, but then the $page->exportValues doesn't return them all - so they
never get in to the session container, thus never get returned when I grab
all values from the container in the third call. Debug Output follows...
array(6) { ["conceptType"]=> string(1) "3" ["recordId"]=>
string(6) "100588"
["isSensitiveGroup"]=> array(1) { ["isSensitive"]=> string(0) ""
}
["eventDateGroup"]=> array(1) { ["eventDate"]=> array(3) {
["d"]=> string(1)
"5" ["M"]=> string(2) "11" ["Y"]=> string(4)
"2003" } } ["detail"]=>
string(14) "ewfgregewg poo" ["_qf_edit_next"]=> string(2) "OK" }
array(4) { ["conceptType"]=> string(1) "3" ["recordId"]=>
string(6) "100588"
["isSensitiveGroup"]=> array(1) { ["isSensitive"]=> string(0) ""
}
["_qf_edit_next"]=> string(2) "OK" }
array(3) { ["conceptType"]=> string(1) "3" ["recordId"]=>
string(6) "100588"
["isSensitiveGroup"]=> array(1) { ["isSensitive"]=> string(0) ""
} }
I would appreciate very much any help or pointers on what can cause these
differences?
Thanks,
Mike C.
________________________________________________________________________
This email has been scanned for all viruses by the MessageLabs Email
Security System. For more information on a proactive email security
service working around the clock, around the globe, visit
http://www.messagelabs.com
________________________________________________________________________