I am trying to position the popup below:
<div style="display:none;height:200px;width:200px;border:3px solid green;" id="popup">Hi</div>
based on the click of another div.
I run this on a .ready document
$('div#d').bind('click', function (event) { var offset = $(this).offset(); $('#popup').css('left',offset.left); $('#popup').css('top',offset.top); $('#popup').css('display','inline'); });
but the div will not be displayed above
source share