javascript - jQuery: How to get the style attribute for "position" of an element? -


this question has answer here:

what proper mark-up in jquery (or javascript) style attribute "position" element in dom?

example:

html

<div id="parent">     parent element     <ul class="child">         <li>             <p>inner child elements</p>         </li>     </ul> </div> 

css

#parent {     position: relative; } .child {     position: absolute; } 

javascript:

$(function() {     //  type here "style attribute position" of #parent? }) 

$('#someelementid').css('position'); 

http://api.jquery.com/css/


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -