I am trying to make sense of the Forward command.

I am utilizing QuickForm in a join form

The user fills in the form if it validates I want to forward to a validate
Action - just for separation.

        // Try to validate a form 
        if ($form->validate()) {

                // Email and store in DB
            // Forward to the Verification controller
            self::_forward('validate');

        } else {
            $string = $form->toHtml();
        }

Now in my validate action I want to forward again to the second stage of the
form

    // Show second stage
    public function validateAction()
    {
//        $post = Zend::registry('post');
//        echo '<pre>'; print_r($post); echo '</pre>';
//        echo '<pre>'; print_r($_POST); echo '</pre>';

        // Forward to the Verification controller
        self::_forward('index', 'verification');
    }

Which involves verification

However when I get here I have the output of all the previous pages.

So my question is

1. How do I stop output from the action the script forwarded from. Is this
something to do with the Dispatch stuff - can I clear this before I forward
maybe?

2. What performance penalty do I suffer for letting the script compile and
then I clean?

3. Any other tips on how to utilize this sort of thing appreciated

Cheers

Ian

Reply via email to