Notice: Undefined index: filter in \wp-content\plugins\social-media-widget\social-widget.php on line 443 in version 4.0.2.
This error occurs because the code that causes the error is borrowed from the WordPress Text widget. It’s the checkbox that says “Automatically add paragraphs” which (like the checkbox says) automaticly adds paragraphs to the text.
However the checkbox was not borrowed, so like Twanneman stated changing the code on line 443 of \wp-content\plugins\social-media-widget\social-widget.php to:
echo "<div class=\"socialmedia-text\>" . $text . "</div>";
is the cleanest solution.
Note to the plugin developer:
The code for the form of the “Automatically add paragraphs” checkbox (in WordPress 3.9.1) can be found in \wp-includes\default-widgets.php on line 528:
<p><input id="<?php echo $this->get_field_id('filter'); ?>" name="<?php echo $this->get_field_name('filter'); ?>" type="checkbox" <?php checked(isset($instance['filter']) ? $instance['filter'] : 0); ?> />?<label for="<?php echo $this->get_field_id('filter'); ?>"><?php _e('Automatically add paragraphs'); ?></label></p>
and the code to save the value can be found on line 514 of the same file (\wp-includes\default-widgets.php):
$instance['filter'] = isset($new_instance['filter']);
Please update this plugin, because we use it regularly.
Thanks in advance! ??