--- C:\Users\Edward\Webs\drupal\includes\batch.inc 2008-01-15 23:25:58.760000000 -0500 +++ C:\Users\Edward\Webs\drupal\includes\batch.inc.formatted 2008-01-15 23:59:10.387000000 -0500 @@ -1,6 +1,7 @@ array('id' => $batch['id']))); $js_setting = array( 'batch' => array( @@ -85,7 +86,7 @@ ); drupal_add_js($js_setting, 'setting'); drupal_add_js('misc/batch.js', 'core', 'header', FALSE, FALSE); - + $output = '
'; return $output; } @@ -101,10 +102,10 @@ drupal_set_title(t('Error')); return ''; } - + // Perform actual processing. list($percentage, $message) = _batch_process(); - + drupal_json(array('status' => TRUE, 'percentage' => $percentage, 'message' => $message)); } @@ -112,46 +113,45 @@ * Batch processing page without JavaScript support. */ function _batch_progress_page_nojs() { - $batch =& batch_get(); + $batch = &batch_get(); $current_set = _batch_current_set(); - + drupal_set_title($current_set['title']); - + $new_op = 'do_nojs'; - + if (!isset($batch['running'])) { // This is the first page so we return some output immediately. - $percentage = 0; - $message = $current_set['init_message']; + $percentage = 0; + $message = $current_set['init_message']; $batch['running'] = TRUE; } else { // This is one of the later requests: do some processing first. - // Error handling: if PHP dies due to a fatal error (e.g. non-existant // function), it will output whatever is in the output buffer, // followed by the error message. ob_start(); $fallback = $current_set['error_message'] .'