Function __global->intelligent_write_error_inline

Definitions

sources/global3.php

  • Discern the cause of a file-write error, and return an appropriate error message.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$path PATH No No required parameter N/A N/A File path that could not be written
$force_hardcoded boolean No No False N/A N/A Whether to force a hard-coded error message, useful if we have not finished bootstrapping

Returns

  • Message (string or Tempcode)
  • Type: mixed
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Discern the cause of a file-write error, and return an appropriate error message.
 *
 * @param  PATH $path File path that could not be written
 * @param  boolean $force_hardcoded Whether to force a hard-coded error message, useful if we have not finished bootstrapping
 * @return mixed Message (string or Tempcode)
 */

function intelligent_write_error_inline(string $path, bool $force_hardcoded = false)