<script type="text/javascript"> // tooltip for Pict $('.woocommerce-product-details__short-description img').hover(function() { var altText = $(this).attr('alt'); var addingText = '<div class="tooltipText">'+altText+'</div>'; $(this).before(addingText); if ( $( ".tooltipText" ).length > 0 ) { window.onmousemove = function (e) { var x = e.clientX, y = e.clientY; tooltipText[0].style.top = (y + 20) + 'px'; tooltipText[0].style.left = (x + 20) + 'px'; } } }, function() { $(this).parent().find('.tooltipText').remove(); }) </script>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)