Function __global->do_notification_lang

Definitions

sources/notifications.php

  • Wraps do_lang, keeping a record of the last call. You can use when building the notification $message (i.e. the body NOT the subject).This allows notification handlers (e.g. push notifications) to possibly repeat the call with very customised output.See do_lang for more documentation.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$codename ID_TEXT No No required parameter N/A N/A The language string codename
$parameter1 ?mixed No No Null N/A N/A The first parameter [string or Tempcode] (replaces {1}) (null: none)
$parameter2 ?mixed No No Null N/A N/A The second parameter [string or Tempcode] (replaces {2}) (null: none)
$parameter3 ?mixed No No Null N/A N/A The third parameter (replaces {3}). May be an array of [of string or Tempcode], to allow any number of additional args (null: none)
$lang ?LANGUAGE_NAME No No Null N/A N/A The language to use (null: user's language)
$require_result boolean No No True N/A N/A Whether to cause the software to exit if the lookup does not succeed

Returns

  • The human-readable content (null: not found). The same type as $parameter1.
  • Type: ?mixed
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Wraps do_lang, keeping a record of the last call. You can use when building the notification $message (i.e. the body NOT the subject).This allows notification handlers (e.g. push notifications) to possibly repeat the call with very customised output.See do_lang for more documentation.
 *
 * @param  ID_TEXT $codename The language string codename
 * @param  ?mixed $parameter1 The first parameter [string or Tempcode] (replaces {1}) (null: none)
 * @param  ?mixed $parameter2 The second parameter [string or Tempcode] (replaces {2}) (null: none)
 * @param  ?mixed $parameter3 The third parameter (replaces {3}). May be an array of [of string or Tempcode], to allow any number of additional args (null: none)
 * @param  ?LANGUAGE_NAME $lang The language to use (null: user's language)
 * @param  boolean $require_result Whether to cause the software to exit if the lookup does not succeed
 * @return ?mixed The human-readable content (null: not found). The same type as $parameter1.
 */

function do_notification_lang(string $codename, $parameter1 = null, $parameter2 = null, $parameter3 = null, ?string $lang = null, bool $require_result = true)