CSS implementation of the left and right two columns width of the middle column width fixed

Source: Internet
Author: User

CSS implementation of the left and right two columns of the width of the adaptive middle column width fixed:
More time may be set left and right two columns width fixed, the middle column width adaptive, but this chapter is the opposite, the following describes how to achieve the middle column width fixed, left and right two column width adaptive, about the left and right two columns fixed, left and right width self-adaptation can see The left and right two column widths fixed the middle column Width Adaptive code example section.
code example:

<!DOCTYPE HTML><HTML><Head><MetaCharSet= "Utf-8"><Metaname= "Author"content= "http://www.softwhy.com/" /><title>Ant Tribe</title><styletype= "Text/css">*{margin:0;padding:0;}Body{font-family:Verdana, Arial, Helvetica, Sans-serif;Min-width:620px;}#header, #footer{Clear:both;padding:10px;text-align:Center;}#left, #right{float: Left;width:50%;margin:0 0 0-151px;}#innerLeft, #innerRight{margin:0 0 0 151px;Background-color:#efefef;}#middle{float: Left;width:300px;Background-color:#ccc;}. Inner{padding:12px;text-align:Center;font-size:12px;}</style></Head><Body><DivID= "Left">  <DivID= "Innerleft"class= "inner">Left column</Div></Div><DivID= "Middle">  <DivID= "Innermiddle"class= "inner">Middle Column</Div></Div><DivID= "Right">  <DivID= "Innerright"class= "inner">Right column</Div></Div></Body></HTML>

The above code realizes our requirements, can achieve the middle column size fixed, both ends of the column width adaptive effect.

The original address is: http://www.softwhy.com/forum.php?mod=viewthread&tid=15086

For more information, refer to: http://www.softwhy.com/divcss/

CSS implementation of the left and right two columns width of the middle column width fixed

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.