RE: [PEAR] QFC - passing values between pages
| From: | Mike Carter | Date: | Tue, 14 Oct 2003 16:13:03 +0000 |
| Subject: | RE: [PEAR] QFC - passing values between pages | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-8435@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: Mike Carter [mailto:mikeatwork@ukonline.co.uk]
>
>
> > -----Original Message-----
> > From: Alexey Borzov [mailto:borz_off@cs.msu.su]
> >
> > Hi!
> >
> > Mike Carter wrote:
> > > I wasn't expecting a nice hacky style method :)
> > > Still, I'm not quite sure what good the ->container()
> method is? It
> > > returns me the contents of the container, but how to I add a new
> > > custom entry to it?
> >
> > Like this:
> >
> > $data =& $controller->container(); // note the reference
> > $data['_mikes_stuff'] = 'some stuff';
> >
> > > Is it not just a case of hacking
> > > $_SESSION['_registration_container']...
> >
> > Well, basically the answer is yes. :]
> > But this stuff is public for a reason, so do not expect any
> breaks in
> > the future.
>
> Hmm, it looks like your example is just like I tried. The
> code below runs in an Action attached to my "register" button.
>
> $container =& $page->controller->container();
> $container['membershipNumber'] = $result; $goto =&
> $page->controller->getPage('success');
> $goto->handle('jump');
>
> $result is being set from a confirmation process.
Any ideas on why values I add to the $container do not get remembered when I
retrieve them with...
$values = $this->controller->exportValues();
var_dump($values);
...On the following page?
It's starting to irritate now - spent an hour fiddling :-/
Can anybody write the documentation for exportValues() too? Or at least,
its not in the current build of the PEAR manual on-line.
Any help appreciated.
Regards,
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
________________________________________________________________________