Relative Positioning
Example
Example
A relative positioned element is positioned relative to its normal position.
Example
h2.pos_left
{
position:relative;
left:-20px;
}
h2.pos_right
{
position:relative;
left:20px;
}
{
position:relative;
left:-20px;
}
h2.pos_right
{
position:relative;
left:20px;
}
The content of relatively positioned elements can be moved and overlap other elements, but the reserved space for the element is still preserved in the normal flow.
Example
h2.pos_top
{
position:relative;
top:-50px;
}
{
position:relative;
top:-50px;
}
Relatively positioned elements are often used as container blocks for absolutely positioned elements.
Other Topics
CSS : All css dimension properties,CSS : Grouping selectors,CSS : Display - block and inline elements,CSS : Hiding an element - display:none or visibility:hidden,CSS : All css dimension properties,CSS : Grouping selectors,CSS : Nesting selectors,CSS : Relative positioning,CSS : Padding properties,CSS : Padding-shorthand property,CSS : Padding - individual sides,CSS : Cross browser compatibality,CSS : Left and right Aligning by float property,CSS : Left &Amp; Right Aligning By Position Property,CSS : The lang pseudo class,CSS : MEDIA,CSS::STYLING FORMS, mechanical Engineering, English books,Photoshop tutorials,Harry potter,Best 100 english books,Mechanical-old-question-paper,
No comments:
Post a Comment