Open Source Content Management System

midgard_replicator method export_purged

  1. Examples

Exports purged objects.

string export_purged(mixed value, [string startdate], [string enddate]);

Minimum version: 1.8.1

This method takes three parameters:

  • value , classname ( or particular class' object instance ) for which purged objects should be exported
  • startdate optional ISO formatted date
  • enddate optional ISO formatted date

All objects of classname are exported if startdate and enddate are ommited or strictly set to NULL. Also use NULL as startdate or enddate if one if them shouldn't be defined.

Returns valid xml content on success, NULL otherwise.

You should use:

Examples

/* Export all articles which has been previously purged */
$xml = $rep->export_purged("midgard_article"); 

/* Export all articles purged after January, 1st, 2007 */
$article = new midgard_article($guid);
$xml = midgard_replicator::export_purged($article, "2007-01-01 00:00:00", NULL);

/* Export all articles purged before January, 10th, 2007 */
$article = new midgard_article($guid);
$xml = midgard_replicator::export_purged($article, NULL, "2007-01-10 00:00:00");

PHP midgard_replicator

Designed by Nemein, hosted by Anykey