I personally always have controllers with

function add(){
  // anything unique for add
  $this->_addedit();
}

function edit( $id ){
  // anything unique for edit
  $this->_addedit( $id );
}

function _addedit($id){
 // all common add/edit stuff
}


and similar for my views, I have a add.ctp, edit.ctp, but both of
these internally render a _addedit.ctp element.  This is because I
find I do need a little custom functionality in the add / edit actions
and views, but don't have to duplicate all the stuff that is the same.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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