Thank you Thomas that worked perfectly and ironically deleting a file
was what I was after.

Thanks,
Darren

On Feb 8, 12:55 am, Thomas Rabaix <[email protected]> wrote:
> You should use preDelete and postDelete methods.
>
> class YouModel extends BaseModel {
>
>   public function postDelete()
>   {
>     // no your code
>     // ex: unlink($this->file)
>   }
>
>
>
> }
> On Sat, Feb 6, 2010 at 9:54 AM, Absalón Valdés <[email protected]> wrote:
> > hi. you can use a event handler adn the catch delete execution, e.g:
> > class backendConfiguration extends sfApplicationConfiguration
> > {
> >   public function configure()
> >   {
> >         $this->dispatcher->connect('admin.delete_object',
> > array($this,'xmethod'));
> >   }
>
> >   public function xmethod(sfEvent $event)
> >   {
> >           // do some stuff
> >   }
> > }
> > This should work... i think
>
> > 2010/2/5 Darren884 <[email protected]>
>
> > Does anyone have any simple example code I can place into my objects
> >> model to override this function? I need to add some stuff into it.
>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "symfony users" group.
> >> To post to this group, send email to [email protected].
> >> To unsubscribe from this group, send email to
> >> [email protected]<symfony-users%[email protected]>
> >> .
> >> For more options, visit this group at
> >>http://groups.google.com/group/symfony-users?hl=en.
>
> >  --
> > You received this message because you are subscribed to the Google Groups
> > "symfony users" group.
> > To post to this group, send email to [email protected].
> > To unsubscribe from this group, send email to
> > [email protected]<symfony-users%[email protected]>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/symfony-users?hl=en.
>
> --
> Thomas Rabaixhttp://rabaix.net

-- 
You received this message because you are subscribed to the Google Groups 
"symfony users" 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/symfony-users?hl=en.

Reply via email to