1
이것이 내 양식입니다 :다른 컨트롤러로 리디렉션하는 "null 폼"에서 보낸 값을 어떻게 인계합니까?
echo $this->Form->create(null, array('url' => '/offices/addOffice'));
echo $this->Form->input('id', array('type' => 'hidden',
'value' => $this->data['Agency']['id']));
echo $this->Form->end(__('Add Office', true));
이제 addOffice 함수에서이 양식에서 보낸 값을 얻고 싶습니다.
내가 한 것은 :
function addOffice($id = null){
$this->set(compact('id'));
}
하지만 $ id를보기로 보내지 않습니다. 내가 뭘 잘못하고 있죠?