how can i redirect to another action passing 2 or more parameters? this code:
$this->redirect('input/new?year=' . $year . '&month=' . $month);
results in URL:
http://.../input?year=2009&month=9
how can i redirect to another action passing 2 or more parameters? this code:
$this->redirect('input/new?year=' . $year . '&month=' . $month);
results in URL:
http://.../input?year=2009&month=9
Is there a specific reason why you have to use the class redirect method instead of simply header('Location: blahblah'); ?
I think this is no normal symfony behavior. Have you defined some routing rules?
Have you also tried this:
$this->redirect('module/action?'.http_build_query($paramsArray));
Strange thing. Does
$this->redirect('@default?module=input&action=new&year=' . $year . '&month=' . $month);
work for you?
Well, that's normal, "redirect" redirect to an absolute URL. You can do that:
$this->redirect($this->generateUrl('default', array('module' => 'input',
'action' => 'new', 'year' => $year, 'month' => $month)));