jquery: position? -


i trying use jquery position position element relative another.

basically trigger element 15px * 15px.

the target element 200px*200px

i want have,

when click trigger element, have target element positioned top of matches top of trigger,

and have left of target element 5px right of trigger element.

how should this?

(note: $('#target'), $('#trigger');)

use offset in jquery ui position (as trying use), this:

$("#trigger").click(function() {     $("#target").position({       my: "left top",       at: "right top",       of: "#trigger",       offset: "5 0"     }); }); 

Comments

Popular posts from this blog

400 Bad Request on Apache/PHP AddHandler wrapper -

Add email recipient to all new Trac tickets -

php - Change action and image src url's with jQuery -