I am passing var argurmrnt to controller like this
return $this->redirect($this->generateUrl('user_profile', array('var' => $profile->getId())));
THis is my controller
/**
* @Route("/profile", name="user_profile")
* @Template()
*/
public function ProfileAction($var)
{
$em = $this->getDoctrine()->getEntityManager();
But i keep getting error
Controller "xxxx\Controller\UserController::ProfileAction()" requires that you provide a value for the "$var" argument (because there is no default value or because there is a non optional argument after this one).