'business-hub-touch', 'description' => __( 'A widget that displays get in touch details.', 'business-hub' ), 'customize_selective_refresh' => true, ); parent::__construct( 'business-hub', __( 'Business Hub: Get In Touch', 'business-hub' ), $opts ); } /** * Outputs the content for the current widget instance. * * @since 1.0.0 * * @param array $args Display arguments. * @param array $instance Settings for the current widget instance. */ function widget( $args, $instance ) { $title = ! empty( $instance['title'] ) ? $instance['title'] : ''; $bg_photo = ! empty( $instance['background_photo'] ) ? $instance['background_photo'] : ''; echo $args['before_widget']; if( !empty( $bg_photo )){ $bg_photo = 'style="background: url('.esc_url( $bg_photo ).') no-repeat;"'; } ?>