Paul,
hmm, it dont works :/
Could you look at the source please?
And should i pass something to the view and write it in the brackets
after "function add"?

[controller code]
function add()
  {
           if(!empty($this->data))
                   {
                            if($this->HardwareGroup->save($this->data))
                      {
                                    $this->Session->setFlash('saved');
            if (!$this->data['HardwareGroup']['referer']) { $this-
>data['HardwareGroup']['referer'] = $this->referer(); }
                                    
$this->redirect($this->data['HardwareGroup']['referer']);
                            }
                   }
  }
[/controller code]


[some view code]
<?php
echo $form->create('HardwareGroup');
  echo $form->input('HardwareGroup.referer',
array('type'=>'hidden'));
  echo $form->input('description');
echo $form->end('Save');
?>
[/some view code]

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to