Inventory_Presser_Options::boolean_checkbox_setting_callback( string $setting_name, string $checkbox_label )

boolean_checkbox_setting_callback


Description Description

Outputs HTML that renders checkboxes.


Top ↑

Parameters Parameters

$setting_name

(string) (Required) The name of the setting and control

$checkbox_label

(string) (Required) The checkbox label that the user sees


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/class-dealership-options.php

	function boolean_checkbox_setting_callback( $setting_name, $checkbox_label )
	{
		printf(
			'<input type="checkbox" name="%s[%s]" id="%s" %s> <label for="%s">%s</label>',
			INVP::OPTION_NAME,
			$setting_name,
			$setting_name,
			isset( $this->option[$setting_name] ) ? checked( $this->option[$setting_name], true, false ) : '',
			$setting_name,
			$checkbox_label
		);
	}