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

  • Home
  • SEARCH
  • 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 8993715
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:15:16+00:00 2026-06-15T23:15:16+00:00

There are blocks named a,b,c,d inside a bigger fixed-width two-column block. I want d

  • 0

There are blocks named a,b,c,d inside a bigger fixed-width two-column block.

layout

I want d left to c and below a, it is possible to complete it using pure CSS?

What I have tried,

CSS:

.wrapper {
    border: 1px dotted #111;
    width: 360px;
    padding: 20px;
    float: left;
}

.rectangle {
    display: inline-block;
    float: left;
    border: 1px solid #333;
    min-height: 100px;
    width: 178px;
}

#a {
    height: 248px;
}

#b {
    height: 148px;
}

#c {
    height: 198px;
}

#d {
    height: 98px;
}

HTML:

<div class="wrapper">
<div id="a" class="rectangle">a</div>
<div id="b" class="rectangle">b</div>
<div id="c" class="rectangle">c</div>
<div id="d" class="rectangle">d</div>
</div>​

http://jsfiddle.net/imom0/E7GYR/1/

To keep it simple, I prefer not to use JavaScript or masonry.

  • 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-15T23:15:17+00:00Added an answer on June 15, 2026 at 11:15 pm

    You can use the column-count CSS property like this:

    .wrapper {
        border: 1px dotted #111;
        width: 460px;
        padding: 20px;
        float: left;
        column-count:2;
    }
    
    .rectangle {
        display: inline-block;
        border: 1px solid #333;
        min-height: 100px;
        width: 170px; 
    }
    

    and restructure your HTML to:

    <div class="wrapper">
    <div id="a" class="rectangle">a</div>
    <div id="d" class="rectangle">d</div>
    <div id="b" class="rectangle">b</div>
    <div id="c" class="rectangle">c</div>
    </div>
    

    column-count is supported with the respective vendor prefixes by most browsers. See caniuse for more infos.

    An example fiddle can be found here.

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

Sidebar

Related Questions

Suppose I have an HTML page with three blocks of fixed width (their height
I have these div blocks called columns where each column div contains separate two
in the code below at first if statements block (there will be more than
In my iOS application I want to define two block types that take each
Is there any way that regular expression match inside a if block would interfere
I have a content div and inside it there are two div's with background
Is there any addon by which I can disable all catch blocks temporarily. I'm
Java classes are generally divided into logical blocks. Is there a convention to mark
I am working on an assessment system. There are many 'questionItem' blocks on the
There is a problem executing this block of code while passing the parameter. Parameter

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.