How to set margin with jquery?
<p>I am doing this:</p>

<pre><code>var sId=id.toString();
var index=sId.substring(3);
var mrg=index*221;
var el=$(id);
el.css('margin-left',mrg+'px'); and el.css('marginLeft',mrg+'px');
</code></pre>

<p>el is the element i want to set the margin to (correctly retrieved) and mrg is the value of the new margin</p>

<p>If i do $<code>('#test1').css('margin-left',200);</code> or <code>$('#test1').css('marginLeft',200);</code> it works in both ways, it's something wrong with the way i set the property. </p>

<p>The correct way is var <code>el=$('#'+id);</code></p>
