jquery - Faulty image height on website -


i have row of images in current books on website, make images same height, set image html book equal 378 using:

 <img alt="html & css" height= "378" src="html.jpg">   


using jquery, set height of other images in row using this:

 $(window).load(function() {     $(".book-pictures").height($("#html").height());      $(".book-pictures").width($("#html").width());   }); $(window).resize(function(){     $(".book-pictures").height($("#html").height());      $(".book-pictures").width($("#html").width());   }); 

the height of these images uniform good, html book image height smaller others. here html row:

<section id="book-section" class="portfolio">     <div class="container">         <div class="row" id="books">             <div class="col-lg-10 col-lg-offset-1 text-center">                 <h2 class ="small-line">current books</h2>                  <div class="row">                     <div class="col-md-3">                         <div class="portfolio-item" style ="vertical-align: middle">                             <h3>pragmatic programmer</h3>                             <img alt="pragmatic programmer" class="img-portfolio img-responsive img-rounded book-pictures"  src="http://ecx.images-amazon.com/images/i/41bkx1axqwl._sx258_bo1,204,203,200_.jpg" >                         </div>                     </div>                     <div class="col-md-3">                         <div class="portfolio-item">                             <h3>the shellcoders handbook</h3>                             <img alt="the shellcoders handbook" class="img-portfolio img-responsive img-rounded book-pictures" src="http://ecx.images-amazon.com/images/i/51gq-xxfypl._sx395_bo1,204,203,200_.jpg">                         </div>                     </div>                     <div class="col-md-3">                         <h3>html & css </h3>                         <div class="portfolio-item">                              <img alt="html & css" height= "378" class="img-portfolio img-responsive img-rounded" id="html" src="http://ecx.images-amazon.com/images/i/41k27grbyml._sx258_bo1,204,203,200_.jpg">                            </div>                     </div>                     <div class="col-md-3">                         <h3>cryptography engineering</h3>                         <div class="portfolio-item">                             <img  alt="snowboarding cat. impressive." class="img-portfolio img-responsive img-rounded book-pictures" id="cat-picture" src="http://ecx.images-amazon.com/images/i/51sehlarm%2bl._sx258_bo1,204,203,200_.jpg">                         </div>                     </div>                 </div>             </div>         </div>     </div> </section> 

could please me make these images uniform?

it not image, faulty. text above them. so, give like:

h3 {   overflow: hidden;   height: 1.5em;   line-height: 1.5em;   white-space: nowrap;   text-overflow: ellipsis; } 

this make headings above in single line , don't need use jquery or javascript either make uniformness. :)

preview


Comments

Popular posts from this blog

html - Firefox flex bug applied to buttons? -

html - Missing border-right in select on Firefox -

c# - two queries in same method -