position
bottom
left
top
PROPERTY: right
right
:
auto
|
length
|
percentage
Compatibility:
IE5+
Version:
Level 2
Inherited:
No
The
right
property sets the physical distance of how far the right content edge of an element is to the left from the right content edge of the containing block.
A containing block is simply an element that contains one or more related elements.
There are three other properties that allow you to set the distance for the
bottom, left,
and
top
content edges. All four properties are used in conjunction with the
position
property. Note that if the
position
property is set to the
static
value, setting the
right
property has no effect.
auto
The
auto
value sets the distance between the right content edges.
length
The
length
value sets the distance between the right content edges and can be in any of the following seven units. Use the abbreviation.
Length
Abbrev.
centimeters
cm
ems
em
inches
in
millimeters
mm
picas
pc
pixels
px
points
pt
percentage
The
percentage
value sets the distance between the right content edges as a percentage of the overall width of the parent block. It is a positive integer number. The percent sign is mandatory.
Code:
p.one {
position: absolute;
bottom: 1in;
left: 1in;
right: 1in;
top: 1in;
}
Output:
Click to view example in separate window
Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information