Width of Figure

While I was working on making my images responsive within posts, I had trouble with images that had captions. I noticed that had an inline width. Just curious what the purpose of that specifically was since images themselves already have an width attribute.

$attributes .= ' style="width: ' . (esc_attr($attr['width']) + 10) . 'px"';


This was a result of Bootstrap’s change to box sizing. The GitHub issue is here but the easiest way to see why it’s needed is to remove it.

1 Like

Ah, I see now. Thanks for the quick response.