Function __global->require_lang_compile

Definitions

sources/lang_compile.php

  • Load up a language file, compiling it (it's not cached yet).
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: bool

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$codename ID_TEXT No No required parameter N/A N/A The language file name
$lang ?LANGUAGE_NAME No No required parameter N/A N/A The language (null: uses the current language)
$type ?string No No required parameter lang_custom custom N/A The language type (lang_custom, or custom) (null: normal priorities are used)
$cache_path PATH No No required parameter N/A N/A Where we are caching too
$ignore_errors boolean No No False N/A N/A Whether to just return if there was a loading error

Returns

  • Whether we FAILED to load
  • Type: boolean
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Load up a language file, compiling it (it's not cached yet).
 *
 * @param  ID_TEXT $codename The language file name
 * @param  ?LANGUAGE_NAME $lang The language (null: uses the current language)
 * @param  ?string $type The language type (lang_custom, or custom) (null: normal priorities are used)
 * @set lang_custom custom
 * @param  PATH $cache_path Where we are caching too
 * @param  boolean $ignore_errors Whether to just return if there was a loading error
 * @return boolean Whether we FAILED to load
 */

function require_lang_compile(string $codename, ?string $lang, ?string $type, string $cache_path, bool $ignore_errors = false) : bool