PHP Class fewbricks\acf\layout

Datei anzeigen Open project: folbert/fewbricks Class Usage Examples

Public Methods

Method Description
__construct ( string $label, string $name, $key )
add_brick ( brick $brick ) Dont add more than one brick to a layout
add_field ( $arg )
add_flexible_content ( flexible_content $flexible_content )
add_repeater ( repeater $repeater )
add_sub_field ( field $field_object )
get_setting ( $key, string $default_value = '' ) : string
get_settings ( ) : array
set_setting ( $name, $value )

Protected Methods

Method Description
add_common_field ( string $common_field_array_key, string $key, array $settings = [] )

Method Details

__construct() public method

public __construct ( string $label, string $name, $key )
$label string
$name string
$key

add_brick() public method

Dont add more than one brick to a layout
public add_brick ( brick $brick )
$brick fewbricks\bricks\brick

add_common_field() protected method

protected add_common_field ( string $common_field_array_key, string $key, array $settings = [] )
$common_field_array_key string A key corresponding to an item in the fewbricks_common_fields array
$key string A site wide unique key for the field
$settings array Anye extra settings to set on the field. Can be used to override existing settings as well.

add_field() public method

public add_field ( $arg )
$arg

add_flexible_content() public method

public add_flexible_content ( flexible_content $flexible_content )
$flexible_content fewbricks\acf\fields\flexible_content

add_repeater() public method

public add_repeater ( repeater $repeater )
$repeater fewbricks\acf\fields\repeater

add_sub_field() public method

public add_sub_field ( field $field_object )
$field_object fewbricks\acf\fields\field

get_setting() public method

public get_setting ( $key, string $default_value = '' ) : string
$key
$default_value string
return string

get_settings() public method

public get_settings ( ) : array
return array

set_setting() public method

public set_setting ( $name, $value )
$name
$value