JQuery UI Position is different if executed on same element more than once -


i using jquery ui position function move div out of hidding , div on screen. works.

$("#b"+num).position({     my: 'left top',     at: parent.data('pos'),//parent set dynamicaly $('#some_div')     of: parent,     collision: 'none' }).show('fast'); 

i have button hides positioned div , yet button bring back. when brought position function run again same parameters. new position in different spot.

i suspect because div moving relative original position changes on first run through. there way reset div when hide goes original position?

run position function after make element visible (e.g. call show , position)

see jquery ui - positioning hidden div using position api not position correctly


Comments

Popular posts from this blog

apache - PHP Soap issue while content length is larger -

asynchronous - Python asyncio task got bad yield -

javascript - Complete OpenIDConnect auth when requesting via Ajax -