Calling redirect() means browser redirection, meaning a new context.
Save the variable in the session, using
$this->getUser()->setAttribute(), or use forward(), that forwards
internally.

On Mon, May 24, 2010 at 12:36, Javier Garcia <tirengar...@gmail.com> wrote:
> Hi,
>
> i have these methods in module1/actions/actions.class.php:
>
>  public function executeMethod1(sfWebRequest $request){
>
>      $a = 10;
>
>      sfContext::getInstance()->set('a', $a);
>      return $this->redirect('module1/method2');
>
>  }
>
>  public function executeMethod2(sfWebRequest $request){
>
>      echo sfContext::getInstance()->get('a');
>
>  }
>
>
> When i execute module1/method1 i get this error:
>
> "The "a" object does not exist in the current context."
>
> Any idea?
>
> --
> Javi
>
> Ubuntu 8.04 - Symfony 1.3
>
> --
> If you want to report a vulnerability issue on symfony, please send it to
> security at symfony-project.com
>
> You received this message because you are subscribed to the Google
> Groups "symfony users" group.
> To post to this group, send email to symfony-users@googlegroups.com
> To unsubscribe from this group, send email to
> symfony-users+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/symfony-users?hl=en
>

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to