Note that there are some explanatory texts on larger screens.

plurals
  1. POhow to enlarge a div on hover without moving other div
    primarykey
    data
    text
    <p>I'm looking to achieve a hover effect like <a href="http://shopper.queldorei.com/index.php/women/dresses.html" rel="nofollow">this hover</a> where the image enlarges but does not displace the surrounding divs. I have seen this done by assigning relative and absolute positioning and a z-index but that isn't working for me. Perhaps I assigned those values to the wrong classes. My code is below...any help is appreciated</p> <p>I wasn't totally sure how to post the code here so...my site (and code problem) can be viewed <a href="http://4ucaps.activo.com/fitted/mlb/?dir=desc&amp;order=position" rel="nofollow">here</a></p> <p>It's my first time posting here. Thanks for the instruction. Here is the code...</p> <p>HTML:</p> <pre><code>&lt;div class="products-container"&gt; &lt;div class="products-container-inner"&gt; &lt;div class="item"&gt; &lt;div class="item"&gt; &lt;div class="item"&gt; &lt;div class="item"&gt; </code></pre> <p>CSS:</p> <pre><code>div.item { height: 135px; width: 150px; margin: 10px; display: inline-block; float: left; } div.item:hover { border: none; float: left; height: 280px; width: 280px; background-color: #ffffff; -moz-box-shadow: 0 0 5px rgba(0,0,0,0.5); -webkit-box-shadow: 0 0 5px rgba(0,0,0,0.5); box-shadow: 0 0 5px rgba(0,0,0,0.5); -webkit-transition: .2s ease; -moz-transition: .2s ease; -o-transition: .2s ease; -ms-transition: .2s ease; transition: .2s ease; } div.products-container-inner { margin: auto; width: 100%; border: none; padding: 10px; overflow: hidden; } div.item .product-name { text-align: center; display: none; } div.item:hover .product-name { text-align: center; display: block; } div.item .price-box { text-align: center; display: none; } div.item:hover .price-box { text-align: center; display: block; } div.item .btn { background-color: #EE432E; background-image: -moz-linear-gradient(center top , #EE432E 0%, #C63929 50%, #B51700 50%, #891100 100%); border: 1px solid #951100; border-radius: 5px 5px 5px 5px; box-shadow: 0 0 0 1px rgba(255, 115, 100, 0.4) inset, 0 1px 3px #333333; color: #FFFFFF; font: normal 16px/1 "helvetica neue",helvetica,arial,sans-serif; padding: 3px 0; float: left; margin-left: 65px; text-shadow: 0 -1px 1px rgba(0, 0, 0, 0.8); text-decoration: none; width: 150px; display: none; } div.item:hover .btn { text-align: center; display: block; background-color: #F37873; background-image: -moz-linear-gradient(center top , #F37873 0%, #DB504D 50%, #CB0500 50%, #A20601 100%); cursor: pointer; } div.item:active .btn { background-color: #D43C28; background-image: -moz-linear-gradient(center top , #D43C28 0%, #AD3224 50%, #9C1500 50%, #700D00 100%); box-shadow: 0 0 0 1px rgba(255, 115, 100, 0.4) inset; } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload