Person
extends Datum
in package
Person element
Tags
Table of Contents
Properties
- $directory : mixed
Methods
- __construct() : mixed
- Construct an element with an associated directory
- metadata() : mixed
- Return the metadata of the element
- metadata_fields() : array<string|int, mixed>
- Return the metadata fields of the person.
Properties
$directory
public
static mixed
$directory
Methods
__construct()
Construct an element with an associated directory
public
__construct(string $directory) : mixed
Parameters
- $directory : string
-
the path to the associated directory.
Tags
metadata()
Return the metadata of the element
public
metadata() : mixed
Every element has a metadata.json
file in the associated directory.
This method loads and returns that JSON.
Tags
Return values
mixed —The loaded json metadata file in appropriate PHP type.
metadata_fields()
Return the metadata fields of the person.
public
metadata_fields() : array<string|int, mixed>
Every person metadata inherit all the metadata of the Datum
plus:
-
surname
: surname of the person -
img_src
: img src of the person -
social_links
: social links of the person (in JSON format)
Tags
Return values
array<string|int, mixed> —Names of the metadata fields of the element.