Re: HTML Quickform Controller Question ...
| From: | Alexey Borzov | Date: | Sat, 15 Nov 2003 09:11:43 +0000 |
| Subject: | Re: HTML Quickform Controller Question ... | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-8963@lists.php.net to get a copy of this message | ||
Hi!
Donald Lobo wrote:
I'm trying to do the foll: Assume a 3 page wizard: p1 -> p2 -> p3 (got this working fine) lets assume based on some "user input value" on page p1 we want to change the flow to: so basically i want the code to fork after p1 based on some user input to do additional processing p1 -> p2a -> p2b -> p2 -> p3 how do i go about doing this, i checked the examples and the documentation and did not find a clean way to handle this. Note that the pages are sufficiently complex that i'd like seperate pages rather than just including the fields conditionally on page p2First of all, you'll need to add all 5 pages to Controller. There can be problems if you try to add only p1, p2 and p3. You'll probably need to add a custom 'next' handler on page p1 that will redirect either to p2a or p2 (and mark p2a and p2b as valid in this case!) and a custom 'back' handler on p2, that will redirect to either p2b or p1. Read the docs, it's all mostly described there.