function system_test_drupal_set_message
Sets two messages and removes the first one before the messages are displayed.
1 string reference to 'system_test_drupal_set_message'
- system_test_menu in modules/
simpletest/ tests/ system_test.module - Implements hook_menu().
File
-
modules/
simpletest/ tests/ system_test.module, line 510
Code
function system_test_drupal_set_message() {
// Set two messages.
drupal_set_message('First message (removed).');
drupal_set_message('Second message (not removed).');
// Remove the first.
unset($_SESSION['messages']['status'][0]);
return '';
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.