You are here

function data_export_import_batch_export_nodes_finished in Data export import 7

Batch 'finished' callback.

1 string reference to 'data_export_import_batch_export_nodes_finished'
data_export_import_export_nodes_to_file in includes/profiles/nodes.inc
Export the required dataset files.

File

includes/profiles/nodes.inc, line 397
Enables nodes to be exported and imported.

Code

function data_export_import_batch_export_nodes_finished($success, $results, $operations) {
  if ($success) {

    // Here we do something meaningful with the results.
    $message = t('The following dataset files were created:');
    $message .= theme('item_list', array(
      'items' => $results,
    ));
  }
  else {

    // An error occurred. $operations contains the operations that
    // remained unprocessed.
    $error_operation = reset($operations);
    $message = t('An error occurred while processing %error_operation with arguments: @arguments', array(
      '%error_operation' => $error_operation[0],
      '@arguments' => print_r($error_operation[1], TRUE),
    ));
  }
  drupal_set_message($message);
}