Hi,
I have been trying for hours, but i cant figure out how to update the message and percentage for the status bar in an ajaxified form.
Anyone can point me to a working example that uses the #ajax['progress']['url'] or #ajax['progress']['interval'] properties?
I declare the ajaxified button like this in my module:
$form['synchronisation']['submit'] = array(
'#type' => 'submit',
'#value' => t('Import cursus data'),
'#submit' => array(), ,
'#weight' => 10,
'#ajax' => array(
'callback' => 'mymodule_admin_settings_submit',
'wrapper' => 'progress',
'progress' => array('type' => 'bar', 'message' => 'TestMessage',),
),
);
This shows a progress bar and the message. But as the callback function runs, i would like to send new messages and update the progress. I also tried adding url to the progress-array and declared a MENU_CALLBACK path to a function that returned a message. But this leads to AJAX-errors.
I cannot find any code example where the progress bar is updated... Just a link with such an example would probably save me!
From the documentation at the API Reference
#ajax['progress']