PHP 클래스 Kirki, kirki

상속: extends Kirki_Init
파일 보기 프로젝트 열기: aristath/kirki 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$config array An array containing all configurations.
$fields array An array containing all fields.
$panels array An array containing all panels.
$path string Absolute path to the Kirki folder.
$sections array An array containing all sections.
$url string URL to the Kirki folder.

공개 메소드들

메소드 설명
add_config ( string $config_id, array $args = [] ) Sets the configuration options.
add_field ( string $config_id, array $args ) Create a new field.
add_panel ( string $id = '', array $args = [] ) Create a new panel.
add_section ( string $id, array $args ) Create a new section.
get_option ( string $config_id = '', string $field_id = '' ) : mixed Get the value of an option from the db.

메소드 상세

add_config() 공개 정적인 메소드

Sets the configuration options.
public static add_config ( string $config_id, array $args = [] )
$config_id string The configuration ID.
$args array The configuration options.

add_field() 공개 정적인 메소드

Create a new field.
public static add_field ( string $config_id, array $args )
$config_id string The configuration ID for this field.
$args array The field arguments.

add_panel() 공개 정적인 메소드

Create a new panel.
public static add_panel ( string $id = '', array $args = [] )
$id string The ID for this panel.
$args array The panel arguments.

add_section() 공개 정적인 메소드

Create a new section.
public static add_section ( string $id, array $args )
$id string The ID for this section.
$args array The section arguments.

get_option() 공개 정적인 메소드

Get the value of an option from the db.
public static get_option ( string $config_id = '', string $field_id = '' ) : mixed
$config_id string The ID of the configuration corresponding to this field.
$field_id string The field_id (defined as 'settings' in the field arguments).
리턴 mixed The saved value of the field.

프로퍼티 상세

$config 공개적으로 정적으로 프로퍼티

An array containing all configurations.
public static array $config
리턴 array

$fields 공개적으로 정적으로 프로퍼티

An array containing all fields.
public static array $fields
리턴 array

$panels 공개적으로 정적으로 프로퍼티

An array containing all panels.
public static array $panels
리턴 array

$path 공개적으로 정적으로 프로퍼티

Absolute path to the Kirki folder.
public static string $path
리턴 string

$sections 공개적으로 정적으로 프로퍼티

An array containing all sections.
public static array $sections
리턴 array

$url 공개적으로 정적으로 프로퍼티

URL to the Kirki folder.
public static string $url
리턴 string