[thelist] Moving a <div> with javascript

Mark Kennedy mark at eurogamer.net
Tue Mar 11 10:55:38 CST 2003


Same problem I think: not using 'px' after your units, but in your inline styles
this time.  It's best never to assume that the browser can guess your units in
CSS.

Mark


On Tue, 11 Mar 2003, Hershel Robinson wrote:

>> try this:
>>
>> function right()
>> {
>> i = parseInt(document.getElementById("watch01").style.left);i++;
>> document.getElementById("watch01").style.left = (i +
>> "px");timer=setTimeout("right()",10);
>> }and the same idea for function left()
>
>I just happened to be doing a scroll function today and I used this code
>(more or less).  It works but I can't get the CSS clip code to work if I
>have an XHTML DOCTYPE.  Here are two pages with the exact same code.  The
>plain one works but the scrollX one does not work.  The only difference is
>the DOCTYPE header.
>
>http://hclic.gwsystems.co.il/scroll.htm
>http://hclic.gwsystems.co.il/scrollX.htm
>
>I am actually only testing this in Win/IE6 because that's all I need it to
>work in.
>
>Any ideas as to what I am doing wrong?
>
>Thanks,
>Hershel
>
>-- 
>* * Please support the community that supports you.  * *
>http://evolt.org/help_support_evolt/
>
>For unsubscribe and other options, including the Tip Harvester 
>and archives of thelist go to: http://lists.evolt.org 
>Workers of the Web, evolt ! 
>

 



More information about the thelist mailing list