_batch_progress_page_js
includes/batch.inc, строка 68
- Версии
- 6
_batch_progress_page_js()
Batch processing page with JavaScript support.
Код
<?php
function _batch_progress_page_js() {
$batch = batch_get();
// The first batch set gets to set the page title
// and the initialization and error messages.
$current_set = _batch_current_set();
drupal_set_title($current_set['title']);
drupal_add_js('misc/progress.js', 'core', 'header', FALSE, FALSE);
$url = url($batch['url'], array('query' => array('id' => $batch['id'])));
$js_setting = array(
'batch' => array(
'errorMessage' => $current_set['error_message'] .'<br/>'. $batch['error_message'],
'initMessage' => $current_set['init_message'],
'uri' => $url,
),
);
drupal_add_js($js_setting, 'setting');
drupal_add_js('misc/batch.js', 'core', 'header', FALSE, FALSE);
$output = '<div id="progress"></div>';
return $output;
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии