Advertisement
gavwagner21

HTML and CSS 3 Column Layout

Feb 25th, 2020
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.97 KB | None | 0 0
  1. <div class="col-wrap">
  2. <div class="main-content">
  3. <article>
  4. Text 1
  5. </article>
  6. <article>
  7. Text 2
  8. </article>
  9. </div><!-- end main content-->
  10. <div class="sidebar">
  11. <article>
  12. Text 3
  13. </article>
  14. </div><!--Close sidebar-->
  15. </div><!--close col-wrap-->
  16. <footer>
  17. <p>These forecasts will be updated every Monday afternoon</p>
  18. </footer><!--close wrapper-->
  19. </div>
  20. </body>
  21. </html>
  22.  
  23. CSS-------------------------------------------------------------------------------------------------------------------------
  24.  
  25. .main-content{
  26. width:66%;
  27. float: left;
  28. padding: 2%
  29. }
  30. .sidebar{
  31. width: 26%;
  32. float: left;
  33. padding: 2%
  34. }
  35. footer{
  36. clear: both;
  37. padding-left:8%;
  38. padding-bottom:10%;
  39. }
  40. wrapper{
  41. width:75%;
  42. margin: auto;
  43. }
  44. img{
  45. width:45%;
  46. height:25%;
  47. }
  48. header{
  49. padding-left:7%;
  50. padding-right:7%
  51. }
  52. article{
  53. padding-left:3%;
  54. padding-right:3%
  55. }
  56. nav{
  57. padding-left:10%;
  58. padding-right:10%;
  59. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement