div position

P

pierre

Hello,

I have a page with 2 divs :

<div id="box_out" style="position: absolute; width: 600px; height: 500px;
overflow: scroll; border: 1px solid #f00;">
<div id="box_in" style="position: absolute; width: 550px; overflow: visible;
border: 1px solid #00f;">
This is some text<br>
This is some text<br>
This is some text<br>
</div>
</div>

I'd like to move the div "box_in".
I tried :

document.getElementById("box_in").style.top = 100 ; # IE / opera => no
problem, but no move in Firefox !
document.getElementById("box_in").style.posTop = 100 ; # IE / opera => no
problem, but no move in Firefox again !

Can you tell me how to move the "box_in" dynamicaly with Firefox ?

Many thanks in advance,
 
P

pierre

pierre said:
Hello,

I have a page with 2 divs :

<div id="box_out" style="position: absolute; width: 600px; height: 500px;
overflow: scroll; border: 1px solid #f00;">
<div id="box_in" style="position: absolute; width: 550px; overflow:
visible; border: 1px solid #00f;">
This is some text<br>
This is some text<br>
This is some text<br>
</div>
</div>

I'd like to move the div "box_in".
I tried :

document.getElementById("box_in").style.top = 100 ; # IE / opera => no
problem, but no move in Firefox !
document.getElementById("box_in").style.posTop = 100 ; # IE / opera =>
no problem, but no move in Firefox again !

Can you tell me how to move the "box_in" dynamicaly with Firefox ?

Many thanks in advance,

oops, document.getElementById("box_in").style.top seems to be ok in
Firefox... I have troubles with the value assigned...
sorry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,431
Messages
2,571,678
Members
48,796
Latest member
Greg L.

Latest Threads

Top