acf_field_oembed::render_field_settings()publicACF 3.6

Create extra options for your field. This is rendered when editing a field. The value of $field['name'] can be used (like bellow) to save extra data to the $field

{} Это метод класса: acf_field_oembed{}

Хуков нет.

Возвращает

null. Ничего.

Использование

$acf_field_oembed = new acf_field_oembed();
$acf_field_oembed->render_field_settings( $field );
$field (обязательный)
-

Список изменений

С версии 3.6 Введена.

Код acf_field_oembed::render_field_settings() ACF 5.10.2

function render_field_settings( $field ) {

	// width
	acf_render_field_setting(
		$field,
		array(
			'label'       => __( 'Embed Size', 'acf' ),
			'type'        => 'text',
			'name'        => 'width',
			'prepend'     => __( 'Width', 'acf' ),
			'append'      => 'px',
			'placeholder' => $this->width,
		)
	);

	// height
	acf_render_field_setting(
		$field,
		array(
			'label'       => __( 'Embed Size', 'acf' ),
			'type'        => 'text',
			'name'        => 'height',
			'prepend'     => __( 'Height', 'acf' ),
			'append'      => 'px',
			'placeholder' => $this->height,
			'_append'     => 'width',
		)
	);

}