'widget_brand_story', 'description' => esc_html__( 'Display Brand Story Section in home page', 'businessdeal') ); $control_ops = array('width' => 200, 'height' => 250); parent::__construct( false, $name=esc_html__('T-Spiral: Brand Story Section','businessdeal'), $widget_ops, $control_ops ); } /** * Back-end widget form. * * @see WP_Widget::form() * */ public function form( $instance ) { $instance = wp_parse_args((array) $instance, array('brandstory_title' => '','page_id0'=>'','page_id1'=>'','page_id2'=>'', 'brand_image' => '', 'select_icons0' =>'','select_icons1' =>'','select_icons2' =>'', 'select_layout' =>esc_html__('Default','businessdeal'))); $brandstory_title = esc_attr($instance['brandstory_title']); $brand_image = esc_url($instance['brand_image']); $select_layout = esc_attr($instance['select_layout']); $brand_design = array( 'default' => esc_html__( 'Default', 'businessdeal' ), 'simple' => esc_html__( 'Simple', 'businessdeal' ), ); for ($i = 0; $i < 2; $i++) { $var = 'page_id'.$i; $defaults[$var] = ''; $select_icons = 'select_icons'.$i; $instance[ $select_icons ] = esc_attr( $instance[ $select_icons ] ); } $instance = wp_parse_args((array)$instance, $defaults); for ($i = 0; $i < 2; $i++) { $var = 'page_id'.$i; $var = absint($instance[$var]); } ?>


style="display:none;" > <?php esc_attr_e('Image preview', 'businessdeal'); ?>

' ','name' => $this->get_field_name( key($defaults) ), 'selected' => $instance[key($defaults)] ) ); ?>

-1, 'post_type' => array( 'page' ), 'post__in' => $page_array, 'orderby' => 'post__in' ) ); if ($select_layout == 'default'){ $custom_class = 'ex_design '; $args['before_widget'] = str_replace('class="', "class=\"$custom_class", $args['before_widget']); } echo $args['before_widget']; $j = 0; ?>

have_posts() ):$get_featured_pages->the_post(); ?>

'; } } }