*/ if ( ! defined( 'ABSPATH' ) ) { exit; // If this file is called directly, abort. } /** * Author Widget * * Class Aarambha_Kits_Block_Widget_1 */ class Aarambha_Kits_Block_Widget_1 extends Base_WP_Widget { /** * Constructor. */ public function __construct() { $this->widget_cssclass = 'widget_block widget-aarambha-kits'; $this->widget_description = esc_html__( 'Displays authors details in post.', 'aarambha-kits' ); $this->widget_name = esc_html__( 'Aarambha Kits: Block Author', 'aarambha-kits' ); $this->settings = array( 'title' => array( 'type' => 'text', 'default' => '', 'label' => esc_html__( 'Title', 'aarambha-kits' ), ), 'image_bg_url' => array( 'type' => 'image', 'default' => '', 'label' => esc_html__( 'Background Image', 'aarambha-kits' ), ), 'author_name' => array( 'type' => 'text', 'default' => '', 'label' => esc_html__( 'Name', 'aarambha-kits' ), ), 'description' => array( 'type' => 'textarea', 'default' => '', 'label' => esc_html__( 'Description', 'aarambha-kits' ), ), 'image_url' => array( 'type' => 'image', 'default' => '', 'label' => esc_html__( 'Avatar', 'aarambha-kits' ), ), 'url_fc' => array( 'type' => 'url', 'default' => '', 'label' => esc_html__( 'Facebook URL', 'aarambha-kits' ), ), 'url_tw' => array( 'type' => 'url', 'default' => '', 'label' => esc_html__( 'Twitter URL', 'aarambha-kits' ), ), 'url_ldn' => array( 'type' => 'url', 'default' => '', 'label' => esc_html__( 'Linkedin URL', 'aarambha-kits' ), ), 'url_ig' => array( 'type' => 'url', 'default' => '', 'label' => esc_html__( 'Instagram URL', 'aarambha-kits' ), ), ); parent::__construct(); } /** * Output widget. * * @see WP_Widget * * @param array $args Arguments. * @param array $instance Widget instance. */ public function widget( $args, $instance ) { $title = apply_filters( 'widget_title', isset( $instance['title'] ) ? $instance['title'] : '' ); $this->widget_start( $args ); ?>
widget_title( $title ); ?>
widget_end( $args ); } }