This code for index
<td><?php echo
$this->Form->postlink('delete',array('controoler'=>'Users','action'=>
'delete',$user['User']['id']));
?> </td>
controller
public function delete($id){
$this->User->id
= $id;
$this->request->is(array('post','put'));
$this->User->delete();
$this->redirect('index');
No comments:
Post a Comment