Пример #1
0
 /**
  * Add a checkbox to turn off email summaries
  * 
  * @param Action $action Action being executed (emailsettings)
  * 
  * @return boolean hook value
  */
 function onEndEmailFormData($action)
 {
     $user = common_current_user();
     $action->elementStart('li');
     $action->checkbox('emailsummary', _('Send me a periodic summary of updates from my network.'), Email_summary_status::getSendSummary($user->id));
     $action->elementEnd('li');
     return true;
 }
 /**
  * Add a checkbox to turn off email summaries
  *
  * @param Action $action Action being executed (emailsettings)
  * @param Profile $scoped Profile for whom settings are configured (current user)
  *
  * @return boolean hook value
  */
 public function onEndEmailFormData(Action $action, Profile $scoped)
 {
     $action->elementStart('li');
     $action->checkbox('emailsummary', _m('Send me a periodic summary of updates from my network'), Email_summary_status::getSendSummary($scoped->id));
     $action->elementEnd('li');
     return true;
 }