Elgg  Version master
Variables
record.php File Reference

Go to the source code of this file.

Variables

 $user = elgg_extract('entity', $vars)
 Generic view to set a notification preference for a specific purpose. More...
 
 $description = elgg_extract('description', $vars)
 
 $purpose = elgg_extract('purpose', $vars)
 
if(! $user instanceof \ElggUser||empty($description)||empty($purpose)) $methods = elgg_get_notification_methods()
 
if(empty($methods)) $method_options = []
 
 foreach ( $methods as $method) = $description
 
 $value = array_keys(array_filter($user->getNotificationSettings($purpose)))
 

Variable Documentation

◆ $description

Definition at line 15 of file record.php.

◆ $method_options

if (empty( $methods)) $method_options = []

Definition at line 26 of file record.php.

◆ $methods

if (! $user instanceof \ElggUser||empty( $description)||empty( $purpose)) $methods = elgg_get_notification_methods()

Definition at line 21 of file record.php.

◆ $purpose

$purpose = elgg_extract('purpose', $vars)

Definition at line 16 of file record.php.

◆ $user

$user = elgg_extract('entity', $vars)

Generic view to set a notification preference for a specific purpose.

The action will handle the saving of the preferences, no need for your own handling

See also
\ElggUser::getNotificationSettings()
\ElggUser::setNotificationSetting()

@uses $vars['entity'] The user for which to show/set the preference @uses $vars['description'] The description of the notification setting @uses $vars['purpose'] For which purpose is the notification setting used

Definition at line 14 of file record.php.

◆ $value

$value = array_keys(array_filter($user->getNotificationSettings($purpose)))

Definition at line 38 of file record.php.

◆ foreach

foreach($methods as $method) (   $methods as) = $description

Definition at line 27 of file record.php.