'alchemyst_form', 'description' => 'Display one of your forms in a widget area.', ); parent::__construct('alchemyst_form', 'Alchemyst Form', $widget_ops); } /** * Outputs the content of the widget * * @param array $args * @param array $instance */ public function widget($args, $instance) { if (!empty($instance['form'])) { // No need to reinvent the weel here. echo do_shortcode('[alchemyst-form id="' . $instance['form'] . '"]'); } else { // Shouldnt be possible really.. ?>