When you hover over an element, a block with text should pop up, implemented with JS like this:
$(document).ready(function() { if($(document).width() > 992) { $('.button').hover(function() { var color = $(this).css('background-color'); $('.morehover').css('border-top-color', color).clearQueue().delay(500).slideDown(); }, function() { $('.morehover').clearQueue().delay(500).slideUp(); }); $('.morehover').hover(function() { $('.morehover').clearQueue().delay(500).slideDown(); }, function() { $('.morehover').clearQueue().delay(500).slideUp(); });}}); And everything would be fine, but when you hover, blocks of all elements open:
How to make the block open only for the active element?
CSS, if necessary:
.morehover { font-size: 12px; line-height: 18px; display: none; background: rgb(255, 255, 255); position: relative; overflow: overlay; z-index: 999999999; padding: 5px; border-top-color: rgb(255, 192, 0); height: 100px; margin-top: -100px; }
UPD: markup
<div class="image"> <img src="<?= $f_phoneImage ?>" alt=""></div> <div class="more"><div class="morehover"><?= nc_edit_inline('morehover', $f_RowID, $cc)?></div> <span><?= nc_edit_inline('Price', $f_RowID, $cc)?></span> <a href="<?= $f_buttonLink ?>" class="button"><?= $f_buttonText ?></a></div> 