function widget($args, $instance) { extract($args); $title = apply_filters('widget_title', $instance['title']); $form = $instance['form']; $template = isset($instance['template']) ? $instance['template'] : ''; echo $before_widget; if ($title) { echo $before_title . $title . $after_title; } bps_display_form($form, $template, 'widget'); echo $after_widget; }
<?php $atts = vc_map_get_attributes($this->getShortcode(), $atts); extract($atts); $template = 'members/' . $template; bps_display_form($form, $template, 'widget');