javascript - Trying to change 'margin-top' attribute -


This is what I am trying to do:

  $ (function ( ) {$ ('Div.item'). CSS ('margin-top', - (closest ('IMG'). Altitude ()) / 2 + 'px';});   

me ' style = "margin-top: XXXXXX; top: 50%" to get where 'XXXXXX' is equal to (('div. Item an img '). Height ()) / 2

=================================== =============================

:

  



  

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

c# - Using Vici cool Storage with monodroid -

python - referencing a variable in another function? -