css - everything going into flex-container -


really new coding , i've been playing flex container project i'm working on. problem i'm having put code after container style seems end in container. im wondering how can stop or start new container. heres code im looking at:

<style> .flex-container {     display: -webkit-flex;     display: flex;     width: 100%;     height: 500px;     background-color: lightgreen; margin: 0px; }  .flex-right{ float: right;  background-color: none;     width: 700px;     height: 100%;     margin: auto;  } .flex-left{     background-color: none;     width: 800px     height: 100%;     margin: 15px 90px; float: left } </style> <body>  <div class="flex-container">   <div class="flex-left"><img src="sample trainer.png" width="400" height="475" alt="" border="0"></div>   <div class="flex-right"> <h1><span style="font-family: arial; font-weight: bold; font-style: normal; text-decoration: none; font-size: 30pt;">sample text here</span></h>  <p><span style="font-family: arial; font-weight: normal; font-style: italic; text-decoration: none; font-size: 24pt;">more sample text here</span></p> </div> </body> </html>  <div id="footer">ending</div> 

when check in browser, see footer ends in flex.container

i hope can me this.

thanks!

you've forgotten close flex-container div </div> before footer. make sure keep html before closing </body> tag. you've got other invalid code in there, </h> instead of </h1>, careful check syntax.

also avoid inline css (including unnecessary span elements). , remember don't want float contents of flex container, flex layout alternative float layout.

.flex-container {      display: -webkit-flex;      display: flex;      width: 100%;      height: 500px;      background-color: lightgreen;  margin: 0px;  }    .flex-right{  float: right;   background-color: none;      width: 700px;      height: 100%;      margin: auto;    }  .flex-left{      background-color: none;      width: 800px      height: 100%;      margin: 15px 90px;  float: left  }
<div class="flex-container">    <div class="flex-left"><img src="sample trainer.png" width="400" height="475" alt="" border="0"></div>    <div class="flex-right">      <h1><span style="font-family: arial; font-weight: bold; font-style: normal; text-decoration: none; font-size: 30pt;">sample text here</span>      </h1>    <p><span style="font-family: arial; font-weight: normal; font-style: italic; text-decoration: none; font-size: 24pt;">more sample text here</span></p>  </div>  </div>    <div id="footer">ending</div>


Comments

Popular posts from this blog

javascript - How to get current YouTube IDs via iMacros? -

c# - Maintaining a program folder in program files out of date? -

emulation - Android map show my location didn't work -