Utilizing display: table-cell
has always been the traditional approach, but Flexbox is paving the way for the future.
Thanks to Flexbox, achieving this layout is now a breeze, especially since all major browsers have adopted its third version as the "standard".
Give the code snippet a try and scroll down to see the results.
.container{
display: -webkit-box;
display: -moz-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
.badge-block{
margin: 0 auto;
}
.img-responsive{
width: 100%;
}
<div class="container"><div class="badge-block"><a href="javascript::" data-toggle="tooltip" title="General Pack Rs.50" class="badge-icon"><img src="http://www.globalniche.net/wp-content/uploads/2013/07/badge1.png" class="img-responsive"> </a></div>(repeating HTML code structure) </div>
For more in-depth knowledge on Flexbox, don't forget to check out the Complete Guide to Flexbox. Additionally, explore Flexy Boxes, a fantastic tool that visually generates prefixed Flex code for you.