Jump to content

Recommended Posts

Hello.

 

I have a simple 2-column full-CSS layout (meaning: no tables). While putting the borders in, I have noticed that they do not show to the extent of the parent div. Let me show you what I mean:

 

#overall_div {
    width: 100%;
}

#column_1 {
    width: 25%;
    float: left;
    border-right: 1px solid #c2c2c2;
}

#column_2 {
    width: 75%;
    float: left;
}

<div id="overall_div">
    <div id="column_1">
        ...random content...
    </div>
    <div id="column_2">
        ...random content...
    </div>
</div>

 

Please note that that is the simplified code that I'm working with.

 

Anyways, if column #1 is "taller" than column #2, than the border will show fine. However, if column #2 is taller than column #1, the border only reaches up to the point where column #1's content ends. Now, I'm aware that CSS is supposed to do this, but is there any workaround?

Link to comment
https://forums.phpfreaks.com/topic/79757-incomplete-border-problem/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.