place a div at a specific distance from the center of the window using Javascript
<p>I'm struggling for a while positioning a div at 100px from the imaginary center of the window.</p>

<p>My code is doing: middle window / 2 + 100px and is not what I want:</p>

<pre><code>var middle = screen.availWidth/2;
var position = middle+300;
document.getElementById('bookmarks').style.left = position + 'px';
</code></pre>

<p>Using this code my DIV is going left and right based on the  window size and I wanted it to be at 100 px from the center not moving at all.</p>

<p>Also I know this is depending on browser.</p>

<p>Any help with this?</p>

<p>Thanks! 
Vic</p>
