File "class-storefront-customizer-control-arbitrary.php"
Full Path: /home/warrior1/public_html/wp-content-20241001222009/themes/storefront/inc/customizer/class-storefront-customizer-control-arbitrary.php
File size: 959 bytes
MIME-type: text/x-php
Charset: utf-8
<?php // @codingStandardsIgnoreLine.
/**
* Class to create a custom arbitrary html control for dividers etc
*
* @package storefront
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
* The arbitrary control class
*/
class Arbitrary_Storefront_Control extends WP_Customize_Control {
/**
* The settings var
*
* @var string $settings the blog name.
*/
public $settings = 'blogname';
/**
* The description var
*
* @var string $description the control description.
*/
public $description = '';
/**
* Renter the control
*
* @return void
*/
public function render_content() {
switch ( $this->type ) {
default:
case 'text':
echo '<p class="description">' . wp_kses_post( $this->description ) . '</p>';
break;
case 'heading':
echo '<span class="customize-control-title">' . esc_html( $this->label ) . '</span>';
break;
case 'divider':
echo '<hr style="margin: 1em 0;" />';
break;
}
}
}