function widget($args, $instance)
 {
     extract($args);
     // these are the widget options
     $title = apply_filters('widget_title', $instance['title']);
     $text = $instance['text'];
     $textarea = $instance['textarea'];
     echo $before_widget;
     // Display the widget
     echo '<div class="widget-text wp_widget_plugin_box">';
     // Check if title is set
     if ($title) {
         echo $before_title . $title . $after_title;
     }
     // Check if text is set
     if ($text) {
         echo '<p class="wp_widget_plugin_text">' . $text . '</p>';
     }
     // Check if textarea is set
     if ($textarea) {
         echo '<p class="wp_widget_plugin_textarea">' . $textarea . '</p>';
     }
     echo '</div>';
     wpb_related_pages();
     echo $after_widget;
 }
 function widget($args, $instance)
 {
     extract($args);
     // these are the widget options
     $title = apply_filters('widget_title', $instance['title']);
     $text = $instance['text'];
     $textarea = $instance['textarea'];
     echo $before_widget;
     // Display the widget
     echo '<div>';
     // Check if title is set
     if ($title) {
         echo '<div class="related-links-widget-title">' . $title . '</div>';
     }
     // Check if text is set
     if ($text) {
         echo '<p>' . $text . '</p>';
     }
     // Check if textarea is set
     if ($textarea) {
         echo '<p>' . $textarea . '</p>';
     }
     echo '</div>';
     // display related pages
     wpb_related_pages();
     //display related posts
     wpb_related_posts();
     echo $after_widget;
 }