Symfony1 1如何在symfony 1.0.17中获取HTTP_REFERER

Symfony1 1如何在symfony 1.0.17中获取HTTP_REFERER,symfony1,action,referer,Symfony1,Action,Referer,我尝试在action.class.php中获取referer public function executeIndex() { $this->setTemplate('index'); $this->referer = $this->getRequest()->getReferer(); } 但没有任何结果:(有人现在怎么解决这个问题 symfony 1.0.17版已解决$this->getContext()->getRequest()->get

我尝试在action.class.php中获取referer

public function executeIndex()
  {
    $this->setTemplate('index');
    $this->referer = $this->getRequest()->getReferer();
  }
但没有任何结果:(有人现在怎么解决这个问题


symfony 1.0.17版

已解决
$this->getContext()->getRequest()->getReferer()