Function __global->get_field_restrict_property

Definitions

sources/form_templates.php

  • Get the value of a scoped field restriction property. Returns "first-found".
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: string

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$property string No No required parameter N/A N/A The name of the property
$field string No No required parameter N/A N/A The name of the field it's scoped for
$page ?string No No Null N/A N/A The page name scoped for (null: current page)
$type ?string No No Null N/A N/A The page type scoped for (null: current type)

Returns

  • The property (null: non-existent)
  • Type: ?string
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get the value of a scoped field restriction property. Returns "first-found".
 *
 * @param  string $property The name of the property
 * @param  string $field The name of the field it's scoped for
 * @param  ?string $page The page name scoped for (null: current page)
 * @param  ?string $type The page type scoped for (null: current type)
 * @return ?string The property (null: non-existent)
 */

function get_field_restrict_property(string $property, string $field, ?string $page = null, ?string $type = null) : ?string