$this->view->random = date('YmdHis').rand(10000, 9999).rand(10000, 9999);
Then we pass it to a form call in controller:
$this->view->form = new Application_Form_ContentGame(array('random'=>$this->view->random));
And in a form, we get it with:
$random = $this->getAttrib('random');
No comments:
Post a Comment