Function __global->handle_conflict_resolution

Definitions

sources/form_templates.php

  • Look for editing conflicts, and setup editing pinging.For particularly sensitive actions, you should pass false for $id and/or $type.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: array

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$id ~?ID_TEXT No No Null N/A N/A The ID we're editing (null: get from environment, 'id', no conflict resolution if not provided) (blank: not using a screen that has an ID) (false: scope against all IDs)
$page_type ~?ID_TEXT No No Null N/A N/A The page type (null: get from environment, 'type') (false: scope against all types on this page)
$only_staff boolean No No False N/A N/A Whether to only care about staff conflicts

Returns

  • A pair: warning details (Tempcode or null), ping URL
  • Type: array
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Look for editing conflicts, and setup editing pinging.For particularly sensitive actions, you should pass false for $id and/or $type.
 *
 * @param  ~?ID_TEXT $id The ID we're editing (null: get from environment, 'id', no conflict resolution if not provided) (blank: not using a screen that has an ID) (false: scope against all IDs)
 * @param  ~?ID_TEXT $page_type The page type (null: get from environment, 'type') (false: scope against all types on this page)
 * @param  boolean $only_staff Whether to only care about staff conflicts
 * @return array A pair: warning details (Tempcode or null), ping URL
 */

function handle_conflict_resolution($id = null, $page_type = null, bool $only_staff = false) : array