Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9194461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T21:25:09+00:00 2026-06-17T21:25:09+00:00

Can anyone tell me how to make a left div fill the remaining space,

  • 0

Can anyone tell me how to make a left div fill the remaining space, without fixing the right div size.

I want the exact opposite of the following example:

.left {float: left; border: 1px solid blue;}
.right {overflow: hidden; border: 1px solid blue;}

The right div should take only the size it needs, the left div should take all the remaining space.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T21:25:10+00:00Added an answer on June 17, 2026 at 9:25 pm

    The right div with a fixed width must float:right; then the left div must stay as it is so it can take its full available width, but since you want the right div to be fixed, you must place it first.

    HTML:

    <div id="parentDiv">
        <div id="rightFixedDiv"></div>
         <div id="leftDynamicDiv></div>
    </div>
    

    CSS:

    #rightFixedDiv
    {
       float:right; 
       border-style:solid; 
       width:100px; 
       height:200px;
    }
    #leftDynamicDiv
    {
       border-style:solid; 
       background-color:blue; 
       overflow:hidden; 
       height:200px;
    }
    

    Check it out, fixed width of 100px: http://jsfiddle.net/dkGbd/
    fixed width of 200px: http://jsfiddle.net/eESTZ/

    Now if you want the opposite, place the left div first, give it a float:left;

    Working example:
    http://jsfiddle.net/UShek/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can anyone tell me how to make a div's background transparent, but with a
I want to make an Android app by using ZXing . Can anyone tell
I want to make a drop-down list from scratch. Can anyone please tell me
Can anyone tell me how to make this happen? It looks like a setting.
Can anyone tell me, how to make shadow, using UIPageViewController, around of my background
Can anyone please tell me how do I make this script run in IE
Can anyone tell me how to make a flexible AppWidgets in Android according to
Can anyone tell me if its possible to make a glow filter effect around
Can anyone tell me which data type i have to use to make my
Can anyone tell me how to make Paint.NET style ToolWindow(s)? Sorry I don't know

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.