Definition at line 15 of file SystemMessagesService.php.
Elgg\SystemMessagesService::__construct |
( |
\ElggSession |
$session | ) |
|
Elgg\SystemMessagesService::addErrorMessage |
( |
|
$error | ) |
|
Elgg\SystemMessagesService::addMessageToRegister |
( |
|
$message, |
|
|
|
$register_name = '' |
|
) |
| |
Add a message(s) to a named register to be displayed.
Messages will not be displayed immediately, but are stored in the queue for later display, usually upon next page load.
The method of displaying these messages differs depending upon plugins and viewtypes. The core default viewtype retrieves messages in views/default/page/shells/default.php and displays messages as javascript popups.
Definition at line 121 of file SystemMessagesService.php.
Elgg\SystemMessagesService::addSuccessMessage |
( |
|
$message | ) |
|
Elgg\SystemMessagesService::count |
( |
|
$register_name = "" | ) |
|
Counts the number of messages, either globally or in a particular register.
- Parameters
-
string | $register_name | Optionally, the register |
- Returns
- integer The number of messages
Definition at line 62 of file SystemMessagesService.php.
Elgg\SystemMessagesService::dumpRegister |
( |
|
$name = '' | ) |
|
Empty and return the given register or all registers.
In each case, the return value is a filtered version of the full registers array.
- Parameters
-
string | $name | The register. Empty string for all. |
- Returns
- array The array of registers dumped
Definition at line 39 of file SystemMessagesService.php.
Elgg\SystemMessagesService::loadRegisters |
( |
|
$accessed_register = '' | ) |
|
|
protected |
Load the registers from the session.
- Parameters
-
string | $accessed_register | The register being accessed |
- Returns
- array
Definition at line 143 of file SystemMessagesService.php.
Elgg\SystemMessagesService::saveRegisters |
( |
array |
$registers | ) |
|
|
protected |
Save the registers to the session.
- Parameters
-
array | $registers | The message registers |
- Returns
- void
Definition at line 159 of file SystemMessagesService.php.
Elgg\SystemMessagesService::$session |
|
protected |
The documentation for this class was generated from the following file: