MT::App::CMS::cms_post_save.$type

This callback is invoked after an object has been saved, and after all other operations have taken place in response to that object being saved, created or updated (associating an entry to categories for example). This callback is invoked as the very last step following an object being saved. In this callback $type refers to the object type.

Input Parameters

  • $cb - a reference to the current MT::Callback object handling this event.
  • $app - a reference to the MT::App::CMS object processing this request.
  • $obj - a reference to the MT::Object being saved.
  • $original - a reference to the original MT::Object prior to it being modified.

Return Value

None.

Example Handler

sub handler {
    my ($cb, $app, $obj, $original) = @_;
    # do something
}

Note: this is different from MT::ObjectName.post_save in that it is called after other related records have been created and/or processed as well.

This page was last updated on 2008-10-01, 17:03.

Leave a note

Have a question? Please use the MT Forums. Notes submitted on documentation should pertain to tips & hints regarding documentation. Your note may be removed once its contents have been integrated into the body of the page.