Doh! I just removed the width and height values from the widget …. When you insert an image the width and height fields below are automatically filled in, so just delete those values and leave those fields blank and ta-da responsive images (if your template supports it) … sorry for the trouble 🙂
Awesome!
Alternatively, I was going to suggest overriding the template for the widget in your theme.
See: http://wordpress.org/extend/plugins/image-widget/other_notes/
brilliant thanks for the advice, got it sorted this way too!
This first fix (deleting sizes in widget box) is not working for me. My image is displaying but not resizing. How exactly do I override the template? I am not expert in php and need more of a step by step. I realize that there is a parameter for image_widget_image_width that can be disabled. How exactly do you do this?
I have the same probleme as eepadmin, I would like to know how modify the “image_widget_image_width” to have a max-width = 100%.
Thank ou for the answer.
http://www.creacoton.fr
So, do we just add, in our custom widget.php:
// Block direct requests
if ( !defined('ABSPATH') )
die('-1');
echo $before_widget;
if ( !empty( $title ) ) { echo $before_title . $title . $after_title; }
echo $this->get_image_html( $instance, true );
image_widget_image_width = "100%";
image_widget_image_height = "auto";
if ( !empty( $description ) ) {
echo '<div class="'.$this->widget_options['classname'].'-description" >';
echo wpautop( $description );
echo "</div>";
}
echo $after_widget;
?>
All I found was a “wink” about how to use these parameters to override settings. I’ll let you know whether the above code works.
no, that just gives me a parse error.
Where do we use these nice responsive override parameters?
Hard code them into the “Custom” settings in widget-admin.php?
I’ll keep mucking around. I don’t know why this is set to Resolved. I will open a new support thread on this topic.