August 1999
Intermediate to advanced
1488 pages
72h 53m
English
layer.left
The left property of the Layer object represents the x-coordinate position of the layer within the document. Changing this property can move the layer left or right.
Listing 7.332 shows how the left property is used to move the layer from left to right across the screen. When the button is clicked, the move() function is called, which moves the layer1 to the left by 60 pixels.
<html>
<head>
<title> Using the left property of the Layer object</title>
</head>
<body>
<script language="JavaScript">
<!-- Hide
// function moves Layer 1 to the left
function move(){
document.layer1.left = document.layer1.left + 10;
}
// End Hide ... |
Read now
Unlock full access