Jump to content

Make a div the full height of a codeblock

Recommended Posts

This is might be a simple question I currently have a code block with this content:



<div style="width: 100%;">
        <div style="width: 75%; height: 100px; float: left; background: green;"> 
           <h3>Left Div </h3>
        <div id="date" style="margin-left: 25%; height: 100px; background: blue;"> 

  .code-block span{

      font-size: .9em !important;
  text-align: center;

If I want both divs to fill the (flexible) height of the code block, how would I do that? Setting them to 100% now just makes them the height of the text in the div.

Link to comment
  • Replies 1
  • Views 1.1k
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.